|
|
|
|
Re: Sql Loader log file result in table? [message #270497 is a reply to message #270492] |
Thu, 27 September 2007 03:47 |
rk1982
Messages: 24 Registered: September 2007
|
Junior Member |
|
|
My target is to capture weather all records are sucessfuly inserted in table by sql loader .That sucess or failure information i need to capture but not in log file it should be any custom table.
Kindly give me a example of it.
|
|
|
|
Re: Sql Loader log file result in table? [message #270512 is a reply to message #270469] |
Thu, 27 September 2007 04:06 |
rk1982
Messages: 24 Registered: September 2007
|
Junior Member |
|
|
Here is an example of log file..
SQL*Loader: Release 9.2.0.1.0 - Production on Wed Sep 26 14:26:02 2007
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
Control File: abc.ctl
Data File: abc.dat
Bad File: abc.bad
Discard File: none specified
(Allow all discards)
Number to load: ALL
Number to skip: 0
Errors allowed: 50
Continuation: none specified
Path used: External Table
Table OUTCOLLECT, loaded from every logical record.
Insert option in effect for this table: APPEND
Column Name Position Len Term Encl Datatype
------------------------------ ---------- ----- ---- ---- ---------------------
CALLNO FIRST * , CHARACTER
CALLINGNO NEXT * , CHARACTER
CREATE DIRECTORY statements needed for files
------------------------------------------------------------------------
CREATE DIRECTORY SYS_SQLLDR_XT_TMPDIR_00000 AS '/oracle/oraclient/rohit'
CREATE TABLE statement for external table:
------------------------------------------------------------------------
CREATE TABLE "SYS_SQLLDR_X_EXT_OUTCOLLECT"
(
CALLNO VARCHAR2(20),
CALLINGNO VARCHAR2(20)
)
ORGANIZATION external
(
TYPE oracle_loader
DEFAULT DIRECTORY SYS_SQLLDR_XT_TMPDIR_00000
ACCESS PARAMETERS
(
RECORDS DELIMITED BY NEWLINE CHARACTERSET US7ASCII
BADFILE 'SYS_SQLLDR_XT_TMPDIR_00000':'abc.bad'
LOGFILE 'abc.log_xt'
READSIZE 1048576
FIELDS LDRTRIM
REJECT ROWS WITH ALL NULL FIELDS
(
CALLNO CHAR(255)
TERMINATED BY ",",
CALLINGNO CHAR(255)
TERMINATED BY ","
)
)
location
(
'abc.dat'
)
)REJECT LIMIT UNLIMITED
INSERT statements used to load internal tables:
------------------------------------------------------------------------
INSERT /*+ append */ INTO OUTCOLLECT
(
CALLNO,
CALLINGNO
)
SELECT
CALLNO,
CALLINGNO
FROM "SYS_SQLLDR_X_EXT_OUTCOLLECT"
statements to cleanup objects created by previous statements:
------------------------------------------------------------------------
DROP TABLE "SYS_SQLLDR_X_EXT_OUTCOLLECT"
DROP DIRECTORY SYS_SQLLDR_XT_TMPDIR_00000
Run began on Wed Sep 26 14:26:02 2007
Run ended on Wed Sep 26 14:26:02 2007
Elapsed time was: 00:00:00.10
CPU time was: 00:00:00.02
|
|
|
Re: Sql Loader log file result in table? [message #270519 is a reply to message #270512] |
Thu, 27 September 2007 04:37 |
|
Michel Cadot
Messages: 68729 Registered: March 2007 Location: Saint-Maur, France, https...
|
Senior Member Account Moderator |
|
|
I provide help only to those who follow the guide.
Please read and follow OraFAQ Forum Guide, especially "How to format your post?" section.
Make sure that lines of code do not exceed 80 characters when you format. Use the "Preview Message" button.
In addition, the data you asked are not in the file you posted, so the answer is easy: you can't extract them from the file.
Regards
Michel
[Updated on: Thu, 27 September 2007 04:48] Report message to a moderator
|
|
|
Please help me on slql * loader [message #270754 is a reply to message #270469] |
Thu, 27 September 2007 23:33 |
rk1982
Messages: 24 Registered: September 2007
|
Junior Member |
|
|
Once loading with sqlloader is done with table it create a log file.Please give me a example(explain how exactly) how to store the log file informaiton in a any custom table.
|
|
|
|
|
|
Re: Please help me on slql * loader [message #270786 is a reply to message #270778] |
Fri, 28 September 2007 00:47 |
rk1982
Messages: 24 Registered: September 2007
|
Junior Member |
|
|
see i just loaded some data from flat file which looks like
ABCCORP,100
BAQCORP,200
in table name CORP(name varchar(20),id int).Which SQLLDR loaded successfuly and created log file.
Now my problem is how to store the information in another custom table which contains how many records loaded in corp table by sqlldr , was the operation successful,any discard,what was the flat file name where load operation done.
Please explain me in deatil how i can achieve this.
|
|
|
|
|
|
Re: Please help me on slql * loader [message #270806 is a reply to message #270794] |
Fri, 28 September 2007 01:24 |
rk1982
Messages: 24 Registered: September 2007
|
Junior Member |
|
|
Loading is not problem i need to store some other informaiton in other table which contain how many records loaded and was the loading successful. Table structure as follows
Log_Info(Record_loaded int,Is_Success int)
|
|
|
|
|
Re: Please help me on slql * loader [message #270822 is a reply to message #270806] |
Fri, 28 September 2007 01:46 |
rk1982
Messages: 24 Registered: September 2007
|
Junior Member |
|
|
see how can i store information weather the sql loader loading was successful or not.and I mean the log file contains information i need to put it in custom table.Is any way ?? please guide me how to acheive this?
|
|
|
|
|
|
|
|
|
|