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

Home -> Community -> Usenet -> c.d.o.tools -> Skip header rows with sql loader

Skip header rows with sql loader

From: Jörg Schönebaum <clickklack_at_gmail.com>
Date: 4 Nov 2005 02:15:35 -0800
Message-ID: <1131099335.116698.109120@g43g2000cwa.googlegroups.com>


Hi.

i have a problem with the skip-function of sql loader.

I use the command-line argument skip to skip 3 header rows. Also my control file looks like that:

LOAD DATA
--characterset WE8PC850
INFILE 'CSV_FILE'
APPEND
INTO TABLE data
WHEN (1) != '*'
TRAILING NULLCOLS
(
[...]
)

The Loader Control File contains a when-clause, which only inserts non-commented data-lines into table "data". So far it works, the skip-command skippes the first 3 lines and the control file starts processing the data-file. All lines which are commented out are skipped.

But today I tried it on another client. Here it works differently. First the when-clause is executed. After that the process skips the 3 lines for the skip-command.

An example, my file looks like this:

*Header1 <- i want to skip

Header2 <- i want to skip
*Header3<- i want to skip

Data1
Data2
*Data3 <- i want to skip

Data4
Data...

Thanks for any help.

Jörg Schönebaum Received on Fri Nov 04 2005 - 04:15:35 CST

Original text of this message

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