Re: SQL*Loader - Commit point reached - logical record count 27

From: Harald Maier <maierh_at_myself.com>
Date: Wed, 03 Sep 2003 17:51:46 +0200
Message-ID: <m365k9na8t.fsf_at_ate.maierh>


hari_om_at_hotmail.com (Hari Om) writes:

> Here is my updated version of my execution.....
>
> SQL> desc h_d_t
> Name Type
> ----------------------------------------------------------------------
> col1 VARCHAR2(3)
> col2 NUMBER(4)
> col3 VARCHAR2(8)
> col4 VARCHAR2(8)
> col5 VARCHAR2(8)
> col6 NUMBER(3)
> col7 NUMBER(8)
> col8 VARCHAR2(1)
> col9 NUMBER(10,2)
> col10 NUMBER(3)
>
> My control file is:
> ----------------------------------------------------------------------
> LOAD DATA
> INFILE '/full_path/hdd.csv'
> INTO TABLE h_d_t
> FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"'
> (
> col1 char "ltrim(rtrim(:col1))",
> col2 integer external,
> col3 char "ltrim(rtrim(:col3))",
> col4 char "ltrim(rtrim(:col4))",
> col5 char "ltrim(rtrim(:col5))",
> col6 integer external,
> col7 integer external,
> col8 char "ltrim(rtrim(:col8))",
> col9 integer external,
> col10 integer external
> )
> ----------------------------------------------------------------------
>
> My CSV File (sample)data is as :
> 120,1992,08221946,02121992,02201992,405,8,,9303.48,0
> 121,1993,08221946,02121992,02201992,405,,,1303.08,0

I did the following and it works fine. Why the conversion? Maybe you start with this fragment. I am not sure which LOCALE you are using? But for example your test data would not work with NLS_LANG=GERMAN. But it works with NLS_LANG=AMERICAN.

,----

| LOAD DATA
| INFILE *
| INTO TABLE h_d_t truncate
| FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"'
| (
| col1,
| col2,
| col3,
| col4,
| col5,
| col6,
| col7,
| col8,
| col9,
| col10
| )
| begindata
| 120,1992,08221946,02121992,02201992,405,8,,9303.48,0
| 121,1993,08221946,02121992,02201992,405,,,1303.08,0
| 
| Commit point reached - logical record count 2
|   2 Rows successfully loaded.

`----

Harald Received on Wed Sep 03 2003 - 17:51:46 CEST

Original text of this message