sqlloader [message #565970] |
Mon, 10 September 2012 03:21 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
![](//www.gravatar.com/avatar/80121f721416fe0f306935bef3e9ad8f?s=64&d=mm&r=g) |
bhanupratap.s
Messages: 18 Registered: September 2012 Location: chennai
|
Junior Member |
![yes](/forum/theme/orafaq/images/yahoo.png)
|
|
Hi experts,
I have written the code for sql loader, I have given termination of file is | , i have given five columns name in sequence
My Requirement is that i want to mapped 100th column from Csv file after 5th column how to do it.
please suggest me.
OPTIONS (ERRORS=100000000)
LOAD DATA
CHARACTERSET UTF8
INTO TABLE "TARGET_STG_AMC"
TRUNCATE
FIELDS TERMINATED BY '|'
TRAILING NULLCOLS
(
GFCID "TRIM(:GFCID)",
CUST_NAME "TRIM(:CUST_NAME)",
COUNTRY_CODE "TRIM(:COUNTRY_CODE)",
ISOLEGALNAME "TRIM(:ISOLEGALNAME)",
COUNTRY_NAME "TRIM(:COUNTRY_NAME)",
ABBREVIATION "TRIM(:ABBREVIATION)",
TRADE_STYLE "TRIM(:TRADE_STYLE)"
)
|
|
|
Re: sqlloader [message #565972 is a reply to message #565970] |
Mon, 10 September 2012 03:38 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
John Watson
Messages: 8964 Registered: January 2010 Location: Global Village
|
Senior Member |
|
|
If your data file is a CSV file, your field delimiter must be a comma ',' not a pipe '|'. That is what CSV means: comma separated values.
|
|
|
Re: sqlloader [message #565973 is a reply to message #565970] |
Mon, 10 September 2012 03:39 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
![](/forum/images/custom_avatars/138761.jpg) |
dariyoosh
Messages: 538 Registered: March 2009 Location: France
|
Senior Member |
|
|
bhanupratap.s wrote on Mon, 10 September 2012 10:21... My Requirement is that i want to mapped 100th column from Csv file after 5th column how to do it.
please suggest me ...
Hello there,
Are you sure that this is the correct SQLLoader control file for updating your table? because here I see only 7 columns, yet you're talking about the 100th column in the CSV file (actually your pipe delimited file) that is read by this SQLLoader control file, for me this is not possible.
Regards,
[Updated on: Mon, 10 September 2012 03:40] Report message to a moderator
|
|
|
|
|
Re: sqlloader [message #565978 is a reply to message #565974] |
Mon, 10 September 2012 04:42 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
![](//www.gravatar.com/avatar/80121f721416fe0f306935bef3e9ad8f?s=64&d=mm&r=g) |
bhanupratap.s
Messages: 18 Registered: September 2012 Location: chennai
|
Junior Member |
![yes](/forum/theme/orafaq/images/yahoo.png)
|
|
so i have to use like this:
OPTIONS (ERRORS=100000000)
LOAD DATA
CHARACTERSET UTF8
INTO TABLE "TARGET_STG_AMC"
TRUNCATE
FIELDS TERMINATED BY '|'
TRAILING NULLCOLS
(
GFCID "TRIM(:GFCID)",
CUST_NAME "TRIM(:CUST_NAME)",
COUNTRY_CODE "TRIM(:COUNTRY_CODE)",
ISOLEGALNAME "TRIM(:ISOLEGALNAME)",
COUNTRY_NAME "TRIM(:COUNTRY_NAME)",
ABBREVIATION "TRIM(:ABBREVIATION)",
TRADE_STYLE "TRIM(:TRADE_STYLE)"
8th column FILLER,
9th column FILLER,
.
.
.
.
.
.
99TH column FILLER,
100th column
)
or there is any other way.
|
|
|
|
|
|
|
Re: sqlloader [message #566018 is a reply to message #565974] |
Mon, 10 September 2012 08:32 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) |
joy_division
Messages: 4963 Registered: February 2005 Location: East Coast USA
|
Senior Member |
|
|
bhanupratap.s wrote on Mon, 10 September 2012 04:55Hi,
1015298029~PRESTIGE GLOBAL EQUITY SDN BHD~CORP~~1015298029~MY~~~~~~~~~~~~~~~~50 JALAN KHAW SIM BEE
That is not a pipe (|) symbol.
|
|
|