SQL/MP Programming Manual for COBOL

Program Execution
HP NonStop SQL/MP Programming Manual for COBOL529758-003
7-2
Using DEFINEs
temporarily gain a controlled subset of another user’s privileges. For more information
about PROGID programs, see the Security Management Guide.
Using DEFINEs
Before running an SQL program file, you can specify DEFINE, PARAM, or ASSIGN
commands. This subsection describes DEFINEs. For information about PARAM and
ASSIGN commands, see the TACL Reference Manual.
You can use DEFINE names in an SQL program to specify the names of SQL catalogs
and objects (tables, views, indexes, partitions, and collations). Use a class CATALOG
DEFINE for a catalog and a class MAP DEFINE for an object.
You enable and disable DEFINEs by using the DEFMODE attribute. If DEFMODE is
ON when a program begins execution, the system propagates the current set of
DEFINEs from the process file segment (PFS) of your TACL process to the new
process. If DEFMODE is OFF, the system propagates only the =_DEFAULTS DEFINE
to the new process. To display the current DEFMODE setting, use the SHOW
DEFMODE command.
You can create, modify, delete, and display DEFINEs with TACL (or SQLCI)
commands, Guardian system procedures, and OSS shell commands. You can also
specify the =_SORT_DEFAULTS DEFINE to control sort operations.
You must set all DEFINE names used in SQL statements before SQL load time unless
your program uses execution-time name resolution.
To determine the DEFINE set used when an SQL program was compiled, use the
EXPLAIN DEFINES option of the SQLCOMP command.
Entering the TACL RUN Command
To execute an SQL program file from a TACL process, use the TACL RUN (or RUND
to invoke the INSPECT program) command. You can enter a RUN command either
explicitly or implicitly by using this syntax:
RUN
executes the program file without invoking the Inspect debugger.
RUND
executes the program file under the control of the Inspect symbolic debugger.
[ RUN[D] ] program-file [ / [ , run-option ]... / ]
[ param-set ]