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!

Sql Loader Error

625911Apr 25 2008 — edited Apr 25 2008
Hello,

  For the first time I am using SQL Loader.

  Oracle9i Enterprise Edition Release 9.2.0.6.0 - Production

  contents of empload.ctl
 
 load data
 infile 'd:\one.csv'
 into table emp
 fields terminated by "," optionally enclosed by '"'		  
 ( EMPNO,ENAME,JOB,MGR,HIREDATE,SAL,COMM,DEPTNO)

 
 Contents of one.csv file
 EMPNO,ENAME,JOB,MGR,HIREDATE,SAL,COMM,DEPTNO
"7,369",SMITH,CLERK,"7,902",17-12-1980,880.00,,20
"7,499",ALLEN,SALESMAN,"7,698",20-02-1981,"1,600.00",300.00,30
"7,521",WARD,SALESMAN,"7,698",22-02-1981,"1,250.00",500.00,30
"7,566",JONES,MANAGER,"7,839",02-04-1981,"3,272.50",,20
"7,654",MARTIN,SALESMAN,"7,698",28-09-1981,"1,250.00","1,400.00",30
"7,698",BLAKE,MANAGER,"7,839",01-05-1981,"2,850.00",,30
"7,782",CLARK,MANAGER,"7,839",09-06-1981,"2,450.00",,10
"7,788",SCOTT,ANALYST,"7,566",09-12-1982,"3,000.00",,20
"7,839",KING,PRESIDENT,,17-11-1981,"5,000.00",,10
"7,844",TURNER,SALESMAN,"7,698",08-09-1981,"1,650.00",0.00,30
"7,876",ADAMS,CLERK,"7,788",12-01-1983,"1,100.00",,20
"7,900",JAMES,CLERK,"7,698",03-12-1981,950.00,,30
"7,902",FORD,ANALYST,"7,566",03-12-1981,"3,000.00",,20
"7,934",MILLER,CLERK,"7,782",23-01-1982,"1,300.00",,10
"4,566",KRISHNA,,,,"4,500.00",,

I executed the following command 


C:\>SQLLDR SSAPLLIVE/SSAPLLIVE CONTROL = D:\EMPLOAD.CTL

SQL*Loader: Release 9.2.0.6.0 - Production on Fri Apr 25 16:19:55 2008

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

SQL*Loader-601: For INSERT option, table must be empty.  Error on table EMP


1. Is it must that table should be empty while loading data into table?


After executing truncate command on emp once again I have given the following command


C:\>SQLLDR SSAPLLIVE/SSAPLLIVE CONTROL = D:\EMPLOAD.CTL

SQL*Loader: Release 9.2.0.6.0 - Production on Fri Apr 25 16:22:21 2008

Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.

Commit point reached - logical record count 16


Could any body please suggest where is the mistake?


Regads
Krishna
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 23 2008
Added on Apr 25 2008
5 comments
9,660 views