SQl * Loader [message #74263] |
Tue, 26 October 2004 00:15 |
Raj
Messages: 411 Registered: November 1998
|
Senior Member |
|
|
Dear All,
Can we write sql statement in loader program.
Because before loading data into table I want validate the record.
for example.
looad data
infile <filename>
insert into
when (01:06) in (select acct_no from table2)
(acct_no position(01:06) char(6),
......
......
)
It is showing error. Is there any alternate solution?
please help me in case you have solution.
Thank you very much.
Raj
|
|
|
Re: SQl * Loader [message #74266 is a reply to message #74263] |
Tue, 26 October 2004 03:27 |
|
Mahesh Rajendran
Messages: 10708 Registered: March 2002 Location: oracleDocoVille
|
Senior Member Account Moderator |
|
|
You can write a before insert trigger in base table.
Write an before insert trigger on the base table . THis trigger should check YOUR integrity.
If this is just primaryKey-foreignkey or parent-child thingy you want enforce, it is better to do it with simple database table level constraints ( primary key, foriegn key) instead of using triggers.
|
|
|