IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

if not abend while inserting records in a table


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Balasudher

New User


Joined: 27 Oct 2006
Posts: 3

PostPosted: Mon Oct 30, 2006 9:27 am
Reply with quote

Hi,
Could you tell while inserting records in a table,
for successful ececution whts the code and steps we need to follow
Back to top
View user's profile Send private message
sbpati

New User


Joined: 11 Oct 2006
Posts: 11

PostPosted: Mon Oct 30, 2006 4:49 pm
Reply with quote

Hi,

After the SQL insert statement according to your requirement you can proceed further with the following statements.Hope this fulfills your requirement.

EVALUATE SQLOCODE
WHEN 0
SET ROW-INSERTED TO TRUE
INSERT SOME PROCESS HERE.......
WHEN -803(DUPLICATES)
SET ROW-NOT-INSERTED TO TRUE
INSERT SOME PROCESS HERE..........
WHEN OTHER
PERFORM DB2-ERROR PROCESS....
END-EVALUATE
Back to top
View user's profile Send private message
View previous topic : : View next topic  
Post new topic   Reply to topic All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts Format data from multiple records usi... SYNCSORT 4
No new posts count contained values of several col... DB2 5
No new posts Sort SMF records? SYNCSORT 6
No new posts To Sort detail records in a file with... SYNCSORT 5
No new posts Identify and write records containing... SYNCSORT 11
Search our Forums:


Back to Top