Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> Re: Help with sqlloader
Roland.
Listed below is a sample of a control file and par file that I use to load data such
as yours each day. Modify the control file and par file to suit your needs, such as
list your column names, data file name, etc.
CONTROL FILE:====
Load Data
Append Into Table glcbgdr trailing nullcols ( GameName TERMINATED BY "," OPTIONALLY ENCLOSED BY '"', SaleDate TERMINATED BY "," "TO_DATE(:SALEDATE,'YYYYMMDD')", WinNbr1 TERMINATED BY ",", WinNbr2 TERMINATED BY ",", WinNbr3 TERMINATED BY ",", WinNbr4 TERMINATED BY ",", WinNbr5 TERMINATED BY ",", WinNbrBG TERMINATED BY ",", TotalSalesAmt TERMINATED BY ",", DeferredSalesAmt TERMINATED BY ",", ANNOPTCNT TERMINATED BY ",", CASHOPTCNT TERMINATED BY ",", TIER2WINNERS TERMINATED BY ",", TIER3WINNERS TERMINATED BY ",", TIER4WINNERS TERMINATED BY ",", TIER5WINNERS TERMINATED BY ",", TIER6WINNERS TERMINATED BY ",", TIER7WINNERS TERMINATED BY ",", TIER8WINNERS TERMINATED BY ",", TIER9WINNERS TERMINATED BY ",")PAR FILE:===
The data file is a text file, comma delimited. The par file is run at the console
prompt (Novell) with the command:
load sqlload parfile=ORA:\data\par\bgdr.par
The manuals can be confusing at times and I know an example can clear up a lot of the
confusion.
ROR mª¿ªm
>>> Roland.Skoldblom_at_ica.se 04/02/01 07:45AM >>>
Hi folks,
(See attached file: mondaytest.txt)(See attached file: describetable.txt)
Can anyone help me to write a ctl-file, for instance called test.ctl, to use when i use sqlloader to import a textfile into the oracle database?
I am including two files here, which you might need. Thanks in advance.
Roland Sköldblom
-- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Ron Rogers INET: RROGERS_at_galottery.org Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051 San Diego, California -- Public Internet access / Mailing Lists -------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).Received on Mon Apr 02 2001 - 07:50:20 CDT
![]() |
![]() |