>>2. How can I specify the SQLSTATE so that NOT FOUND will be the condition?
Binyamin Dissen, Assuming that you are calling the Stored procedure from COBOL, here is an example of how the SQLCODES are handled. https://www.ibm.com/docs/en/db2-for-zos/12?topic=examples-example-cobol-program-that-calls-stored-procedure Thanks, Kolusu ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN