We have a random number generator program that is called by the on-line transactions. This program fetches and updates the next available number from a DB2 table. The on-line transactions always come back with the number and never a -904. We recently installed a batch program that also calls the random number generator, but it is plagued with -904s. Has anyone experienced this and resolved it?
As said look into the Manual. Look for the REASON CODE (an 8 character value in the error message, like REASON 00C90084) under -904 SQLCODE. -904 can happen due to various reasons. Follow the instructions under 'User Response'.