Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

SQLLoader skip first column

user520824Jul 17 2018 — edited Jul 17 2018

Hello,

I have a CSV file to be loaded but would like to skip the first comma separated value all the time. There is no field in the database

to hold the first column so have to skip during loading the first comma separated field is always X in the csv file

x, France, Testing

X, Germany, Testing

X, Poland, Not tested

X, Japan, Not tested

X, USA, Successful

I my control file I have only two fields mapped to the database

OPTIONS (skip = 1, DIRECT=TRUE, ERRORS=999999999, SILENT=DISCARDS)

LOAD DATA

REPLACE

INTO TABLE COUNTRY_LINK

FIELDS TERMINATED BY "," OPTIONALLY ENCLOSED BY '"' trailing nullcols

(

country,

link_status 

)

somehow I have to skip X  and load only the other two values... can someone please advise?

Thanks

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 14 2018
Added on Jul 17 2018
2 comments
1,546 views