Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: SQL*Loader for loading multiple records

Re: SQL*Loader for loading multiple records

From: Jason Judge <jason.judge_at_virgin.net>
Date: Wed, 23 Jun 1999 23:56:07 +0100
Message-ID: <7kroli$2qe$1@nclient3-gui.server.virgin.net>


This may be difficult - don't be surprised if it can't be done (I will stand corrected if need be though). There are more limitations on CSV data files than on fixed-width columns. For example, you cannot miss a field out from a CSV file - each field _must_ be loaded into a database column. There is simply no way to tell SQL*loader to ignore field X in a CSV file.

If you have access to awk (either on Unix or a version such as in MKS Toolkit under NT) then you could try pre-formatting the file before loading. awk is very good at this type of thing, though not so good if your fields are quote-delimited. I have used this technique many times to rearrange the order of columns and split variable-length records into multiple records.

I hope this is of some help.

Regards,

Jason Judge

jairamk_at_geocities.com wrote in message <7krdc4$ge4$1_at_nnrp1.deja.com>...
>Hi! Everyone!
> I have to load to a flatfile with the following format
><Header Fields> <Repeating group>.......
>ie
>col1|col2|col3|col4|col5_1|col5_2|...|col5_n|col6_1|col6_2|...|col6_n
>
>into a table of having the format
>
>(col1,col2,col3,col4,col5,col6)
>
>so essentially one physical record in the file will translate into
>n logical database records... the problem is how do i specify field
>positions in the control file... The examples show how to do it to fixed
>length format files but not with delimited files...
>i am at my wits end with this...
>any help will be great...
>thanx in advance
>jairam
>
>
>Sent via Deja.com http://www.deja.com/
>Share what you know. Learn what you don't.
Received on Wed Jun 23 1999 - 17:56:07 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US