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

To insert SQL Error text message in Audit Log Table..


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

New User


Joined: 09 Jul 2011
Posts: 9
Location: India

PostPosted: Sat Sep 24, 2011 1:05 am
Reply with quote

I made a program to perform insert/delete on a table(main table)...My program also write a log for the operations (insert/delete) performed on this this table in another table(audit log table)...
The program write the log for every successful or failed operation performed on main table in audit log table...I have one field in my audit log table in which i want to move the reason of failure of the operation, if the operation will fail for main table..

I know the reason for sqlcodes like -503 , +100 , -803 ...But i want to insert reason for every SQL code possible...

Is there any variable in SQLCA , from where i can insert the sql error text message into the table..??
Or there is any other way to do it ?
Back to top
View user's profile Send private message
Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1788
Location: Bloomington, IL

PostPosted: Sat Sep 24, 2011 1:24 am
Reply with quote

I shall refrain from commenting on the utility of this, and merely point you to DSNTIAR.
Back to top
View user's profile Send private message
rahul.arora

New User


Joined: 09 Jul 2011
Posts: 9
Location: India

PostPosted: Tue Nov 15, 2011 4:02 pm
Reply with quote

Thanks alot..It works..icon_smile.gif
Back to top
View user's profile Send private message
Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1788
Location: Bloomington, IL

PostPosted: Wed Nov 16, 2011 2:38 am
Reply with quote

You're welcome. icon_smile.gif
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts Error to read log with rexx CLIST & REXX 11
No new posts Load new table with Old unload - DB2 DB2 6
No new posts Error when install DB2 DB2 2
No new posts Pulling a fixed number of records fro... DB2 2
No new posts CLIST - Virtual storage allocation error CLIST & REXX 5
Search our Forums:

Back to Top