5 pts.
 Running Multiple SQL statements through JCL
I need to run multiple sql statements seperatd by ';'. I want the execution to continue for all the SQL statements even if any of the SQLs throws out error. Is it possible?

Software/Hardware used:
ASKED: January 7, 2011  11:05 PM
UPDATED: January 13, 2011  9:08 PM

Answer Wiki:
DB2 for z/OS has several options to exec SQL statements via batch. Take a look at DSNTEP2 and DSNTEP4. They are sample programs that come with DB2. Check them out in the APSG manual. Also DSNTIAUL with the SQL option. I also suggest you check with your DBA or other staff in house - there may be rules to be followed.
Last Wiki Answer Submitted:  January 13, 2011  9:08 pm  by  Meandyou   5,205 pts.
All Answer Wiki Contributors:  Meandyou   5,205 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _


 

Try Running DSNTEP2 and DSNTEP4.

You didn’t say anything about the mainframe OS or DB2 version/release. But the above link gives all of the documentation needed, including multiple examples.

Tom

 108,055 pts.