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 Help --

Re: SQL Loader Help --

From: Sven Boneberger <sven.boneberger_at_xgroup.de>
Date: Wed, 22 Sep 1999 14:08:50 +0200
Message-ID: <37E8C6D2.EE2BD7DD@xgroup.de>

Dave Stienessen schrieb:

> Hi,
> I'm trying to load data into oracle from a sql server bcp character output
> file -- here's the specifics
>
> The error I receive is:
> SQL*Loader-524: partial record found at end of datafile (oraclloadopts.txt)
>
> the table is defined as
> create table OrderProduct
> (
> OrderID NUMBER(6) not null,
> ShippingDate DATE not null,
> ProductID CHAR(10) not null,
> UnitPrice NUMBER(8,2) not null,
> Quantity INTEGER not null,
> )
>
> Here's my control file contents:
>
> OPTIONS (BINDSIZE=100000)
>
> LOAD DATA
> INFILE 'ORDERPRODUCT.TXT'
> BADFILE 'ORDERPRODUCT.BAD'
>
> INTO TABLE ORDERPRODUCT
> FIELDS TERMINATED BY ','
> -- hex code 27 is the single quote
> OPTIONALLY ENCLOSED BY X'27'
> (orderid, shippingdate DATE(23) "YYYY-MM-DD HH24:MI:SS", PRODUCTID,
> UNITPRICE,QUANTITY)
>
> Here's a sample record from the text file
> 78057,1976-04-15 07:44:12.000,' 0INT 0',656.37,5
>
> Does someone know what I'm doing wrong??
> Thanks
> Dave Stienessen

Hello Dave,

I had a similar problem, when i produced an textfile under mswin, transferred it to Unix and tried to import it via sql-loader. I think there is something different about the end-of-file markers between Windows and Unix. The problem disappeared, when i edited the textfile under Unix-vi (I just appended an empty line and deleted it again, then saved the file).

If this is the same problem it may help, if you transfer it from Win to Unix with ascii-ftp, not binary-ftp. I suppose that it converts the eof-markers from Win to Unix correctly..
Greetings
Sven
sven.boneberger_at_xgroup.de Received on Wed Sep 22 1999 - 07:08:50 CDT

Original text of this message

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