ORACLE sqlldr ctl import data oracle ctl text data export import implementation (Environment oracle 9I 9.0.2) bat part (General Part) cd Y: \ 1 sqlplus mobilenew @ oral/password @ Y: \ 1 \ 6. SQL SQL part (export) set time off echo off head off; set heading offset term offset pagesize 0 set colsep ", "--- separate set trims onset feedback offset linesize 1200 spool Y: \ 1 \ character no. .txt select to_char (d. phonenumber), d. sex, d. age, d. customerstatus, d. bookstatus, to_char (d. begintime, 'yyyy-mm-dd hh24: mm: ss'), to_char (d. endtime, 'yyyy-mm-dd hh24: mm: ss'), to_char (d. ordertime, 'yyyy-mm-dd hh24: mm: ss'), d. timelength, d. callstatus, d. callbusinessid from y_customer_info d; spool off/quit/Note: The write method for the ctl import file is as follows: \ C Number import \ textC \ character code .txt 'append into table Y_CUSTOMER_INFO_TEMP_LAOLING1fields terminated by', '-- Here For comma separators to process data. trailing nullcols (PHONENUMBER, SEX, AGE, CUSTOMERSTATUS, BOOKSTATUS, BEGINTIME, ENDTIME, ORDERTIME, TIMELENGTH, CALLSTATUS, CALLBUSINESSID) excel Data Import oracle in CVS format import example: test. the ctl syntax is as follows: Load datainfile 'd:/1/1.csv 'append into table testfields terminated by', '(d,) batchcompute bat statement sqlldr userid = mobilenew/password @ orcl control = 'd: \ 1 \ test. ctl 'Log = d: \ 1 \ log.txt bad = d: \ 1 \ bad.txt csv File Import, TABLE type: date type import column child --- TABLE structure create table fjphone (ITEMNAME VARCHAR2 (50) not null, PHONENUMBER VARCHAR2 (20) not null, CITY VARCHAR2 (10) default '', AREA varchar2 (10) default '', BRAND VARCHAR2 (20) default'', JOBID VARCHAR2 (20) default '', CALLSTATS VARCHAR2 (20) default '', TIMELENGTH VARCHAR2 (20) default '', ORDERTIME date default sysdate // Time column) the ctl file is written as follows: load data infile 'e: \ 4 \ comment 'append into table fjphonefields terminated by', 'trailing NULLCOLS (ITEMNAME, PHONENUMBER, CITY, AREA, BRAND, JOBID, CALLSTATS, TIMELENGTH, ORDERTIME "to_date (: ordertime, '''yyyy-mm-dd''') ")/* Add" to_date (: ordertime, '''yyyy-mm-dd ''')"*/