SQL*Loader problem [message #140470] |
Tue, 04 October 2005 07:16 |
himang
Messages: 282 Registered: March 2005 Location: Bangalore
|
Senior Member |
|
|
I am facing problem while loading data into multiple tables from same INPUT file through single control file using WHEN clause. In the first table "FPD_STG_Errors_Messages"
the data gets loaded correctly but for the other table "FPD_STG_LogDetails", it is inserting NULL into the log_Description field. The number of records are correctly loaded but the field value remains NULL.
If I put the <> condition first then it loads data into "FPD_STG_LogDetails" table and in other table the field description comes as NULL.
Where I am being wrong?
CTL File
Options ( Direct = True)
LOAD DATA
INFILE 'C:\Factory Planner Data\Log Files\fperr602.txt'
BADFILE 'C:\Factory Planner Data\Log Files\FPErr.bad'
DISCARDFILE 'C:\Factory Planner Data\Log Files\FPErr.dis'
TRUNCATE
INTO TABLE FPD_STG_Errors_Messages
WHEN (01:07) = 'Warning'
(
Log_Index SEQUENCE(1,1),
Log_Description Char(4000),
LogFile_ID Constant '1'
)
INTO TABLE FPD_STG_LogDetails
WHEN (01:07) <> 'Warning'
(
Log_Index SEQUENCE(1,1),
Log_Description Char(4000),
LogFile_ID Constant '1'
)
Data in file
START: read routing_data (NULL) (03:01:00)
END: read routing_data (NULL) (03:01:00): 0.000 sec
Warning: deleting mfg order 515763300_1-001 which is no longer pegged.
Warning: deleting mfg order 515885400_1-001 which is no longer pegged.
Warning: deleting mfg order 518833100_1-001 which is no longer pegged.
Warning: deleting mfg order 519245700_1-001 which is no longer pegged
Thanks in advance.
Regards
Himanshu Gupta
|
|
|
|
|
|