Hi Avadh,
For this syntax, is it possible to integrate into the load of the table? I tried adding it in and it failed.
It would seem that the "read" of the CSV file shouldn't encapsulate items with quotes.
I don't seem to recall this happening previously.
INSERT INTO odf_ca_u_hr_staging_role_pr
(id, created_date, created_by, last_updated_date, last_updated_by, partition_code, page_layout,
code, name, field_1, field_2, field_3, field_4, field_5, field_6, field_7, field_8, field_9, field_10)
VALUES
(?, SYSDATE, 1, SYSDATE, 1, 'NIKU.ROOT','odf.u_hr_staging_role_prFrame',
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
]]><sql:param value="${nextDBId}"/>
<sql:param value="${nextDBId}"/>
<sql:param value="${nextDBId}"/>
<sql:param value="${dataRow[0]}"/>
<sql:param value="${dataRow[1]}"/>
<sql:param value="${dataRow[2]}"/>
<sql:param value="${dataRow[3]}"/>
<sql:param value="${dataRow[4]}"/>
<sql:param value="${dataRow[5]}"/>
<sql:param value="${dataRow[6]}"/>
<sql:param value="${dataRow[7]}"/>
<sql:param value="${dataRow[8]}"/>
<sql:param value="${dataRow[9]}"/>
</sql:update>
Original Message:
Sent: Jul 23, 2024 03:12 AM
From: Avadh Maheshwari
Subject: Import CSV files using GEL results enclosed in double quotes
Try this in your query: ( Test it with one column and then add it to all. This is Text Delimiter it will be there.
select (case when col like '"%"' then substring(col, 2, len(col) - 1) else col end)
Original Message:
Sent: Jul 22, 2024 04:39 PM
From: Lowell Wetzel
Subject: Import CSV files using GEL results enclosed in double quotes
Hi All,
I have an issue where I have a CSV Import that I get all results with Double Quotes. My problem is I can't seem to strip off those double quotes to actually use the data.
Is there a flag to set to not include the Double Quotes?
<file:processFileLines delimiter="${fileDelimiter}" embedded="${fileIsEmbedded}"
fileName="${filePath.concat(fileSeparator).concat(fileName)}" indexVar="fileRowNum" var="fileRow">
All my results have Double quotes around the values.
Example: "Closed Complete"