Programming Considerations

To embed SQL within a REXX exec, the host command environment must be changed. The ADDRESS instruction, followed by the name of the environment, is used to change the host command environment. The ADDRESS instruction has two forms; one affects all commands issued after the instruction, and one affects only a single command. For more information about host command environments, see section Changing the Host Command Environment and for more information about the ADDRESS instruction, see section ADDRESS.

The REXX/CICS command environment that supports the REXX/CICS DB2 is:
EXECSQL
the command environment that supports SQL.
Note: EXECSQL is an authorized commands. You must be a REXX/CICS authorized user to use the EXECSQL command environment.

REXX/CICS provides an exec called CICRXTRY that can be used to interactively process REXX statements and commands. CICRXTRY can be pseudo-conversational. The PSEUDO and SETSYS PSEUDO commands are used to turn pseudo-conversational mode on or off. If the environment is set to pseudo-conversational, SQL statements issued from CICRXTRY will be committed. If the environment is set to conversational, any SQL statements issued from the CICRXTRY exec will not be committed and any resources that are locked will remain locked until you exit the CICRXTRY exec or issue a CICS SYNCPOINT command. Similar considerations should be made if embedding SQL statements in lengthy REXX execs.


Reference Reference

Feedback


Timestamp icon Last updated: Tuesday, 7 January 2014


http://pic.dhe.ibm.com/infocenter/cicsts/v5r1/topic/com.ibm.cics.rexx.doc//dfhrx/rvse625.html