ibm-information-center/dist/eclipse/plugins/i5OS.ic.cl_5.4.0.1/strqmprc.htm

420 lines
14 KiB
HTML
Raw Permalink Normal View History

2024-04-02 14:02:31 +00:00
<!doctype html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head><META http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Start Query Management Proc (STRQMPRC)</title>
<link rel="stylesheet" type="text/css" href="../rzahg/ic.css">
</head>
<body bgcolor="white">
<script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<a name="STRQMPRC.Top_Of_Page"></a>
<h2>Start Query Management Proc (STRQMPRC)</h2>
<table width="100%">
<tr>
<td valign="top" align="left"><b>Where allowed to run: </b>All environments (*ALL)<br>
<b>Threadsafe: </b>No
</td>
<td valign="top" align="right">
<a href="#STRQMPRC.PARAMETERS.TABLE">Parameters</a><br>
<a href="#STRQMPRC.COMMAND.EXAMPLES">Examples</a><br>
<a href="#STRQMPRC.ERROR.MESSAGES">Error messages</a></td>
</tr>
</table>
<div> <a name="STRQMPRC"></a>
<p>The Start Query Management Procedure (STRQMPRC) command allows you to run a query management procedure that was saved as a member in a source file.
</p>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<hr size="2" width="100%">
<div>
<h3><a name="STRQMPRC.PARAMETERS.TABLE">Parameters</a></h3>
<table border="1" cellpadding="4" cellspacing="0">
<!-- col1="10" col2="15" col3="30" col4="10" -->
<tr>
<th bgcolor="aqua" valign="bottom" align="left">Keyword</th>
<th bgcolor="aqua" valign="bottom" align="left">Description</th>
<th bgcolor="aqua" valign="bottom" align="left">Choices</th>
<th bgcolor="aqua" valign="bottom" align="left">Notes</th>
</tr>
<tr>
<td valign="top"><a href="#STRQMPRC.SRCMBR"><b>SRCMBR</b></a></td>
<td valign="top">Source member</td>
<td valign="top"><i>Name</i></td>
<td valign="top">Required, Positional 1</td>
</tr>
<tr>
<td valign="top" rowspan="3"><a href="#STRQMPRC.SRCFILE"><b>SRCFILE</b></a></td>
<td valign="top">Source file</td>
<td valign="top"><i>Qualified object name</i></td>
<td valign="top" rowspan="3">Optional, Positional 2</td>
</tr>
<tr>
<td valign="top">Qualifier 1: Source file</td>
<td valign="top"><i>Name</i>, <b><u>QQMPRCSRC</u></b></td>
</tr><tr>
<td valign="top">Qualifier 2: Library</td>
<td valign="top"><i>Name</i>, <b><u>*LIBL</u></b>, *CURLIB</td>
</tr><tr>
<td valign="top"><a href="#STRQMPRC.RDB"><b>RDB</b></a></td>
<td valign="top">Relational database</td>
<td valign="top"><i>Simple name</i>, <b><u>*NONE</u></b>, *CURRENT</td>
<td valign="top">Optional</td>
</tr>
<tr>
<td valign="top"><a href="#STRQMPRC.RDBCNNMTH"><b>RDBCNNMTH</b></a></td>
<td valign="top">Connection Method</td>
<td valign="top"><b><u>*DUW</u></b>, *RUW</td>
<td valign="top">Optional</td>
</tr>
<tr>
<td valign="top"><a href="#STRQMPRC.USER"><b>USER</b></a></td>
<td valign="top">User</td>
<td valign="top"><i>Name</i>, <b><u>*CURRENT</u></b></td>
<td valign="top">Optional</td>
</tr>
<tr>
<td valign="top"><a href="#STRQMPRC.PASSWORD"><b>PASSWORD</b></a></td>
<td valign="top">Password</td>
<td valign="top"><i>Character value</i>, *NONE</td>
<td valign="top">Optional</td>
</tr>
<tr>
<td valign="top"><a href="#STRQMPRC.NAMING"><b>NAMING</b></a></td>
<td valign="top">Naming convention</td>
<td valign="top"><b><u>*SYS</u></b>, *SQL, *SAA</td>
<td valign="top">Optional</td>
</tr>
<tr>
<td valign="top"><a href="#STRQMPRC.ALWQRYDFN"><b>ALWQRYDFN</b></a></td>
<td valign="top">Allow information from QRYDFN</td>
<td valign="top"><b><u>*NO</u></b>, *YES, *ONLY</td>
<td valign="top">Optional</td>
</tr>
<tr>
<td valign="top" rowspan="3"><a href="#STRQMPRC.CMDSRCFILE"><b>CMDSRCFILE</b></a></td>
<td valign="top">Command source file</td>
<td valign="top">Single values: <b><u>*NONE</u></b><br>Other values: <i>Qualified object name</i></td>
<td valign="top" rowspan="3">Optional</td>
</tr>
<tr>
<td valign="top">Qualifier 1: Command source file</td>
<td valign="top"><i>Name</i></td>
</tr><tr>
<td valign="top">Qualifier 2: Library</td>
<td valign="top"><i>Name</i>, <b><u>*LIBL</u></b>, *CURLIB</td>
</tr><tr>
<td valign="top"><a href="#STRQMPRC.CMDSRCMBR"><b>CMDSRCMBR</b></a></td>
<td valign="top">Source member</td>
<td valign="top"><i>Name</i>, <b><u>*FIRST</u></b></td>
<td valign="top">Optional</td>
</tr>
<tr>
<td valign="top"><a href="#STRQMPRC.ALWDSPLAY"><b>ALWDSPLAY</b></a></td>
<td valign="top">Display screens</td>
<td valign="top"><b><u>*YES</u></b>, *NO</td>
<td valign="top">Optional</td>
</tr>
</table>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
</div>
<div> <a name="STRQMPRC.SRCMBR"></a>
<h3>Source member (SRCMBR)</h3>
<p>Specifies the source file member that contains the query management procedure to be run.
</p>
<p>This is a required parameter.
</p>
<dl>
<dt><b><i>name</i></b></dt>
<dd>Specify the name of the member.
</dd>
</dl>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<div> <a name="STRQMPRC.SRCFILE"></a>
<h3>Source file (SRCFILE)</h3>
<p>Specifies the source file that contains the query management procedure to be run.
</p>
<p>This is a required parameter.
</p>
<p><b>Qualifier 1: Source file</b>
</p>
<dl>
<dt><b><u>QQMPRCSRC</u></b></dt>
<dd>IBM-supplied source file QQMPRCSRC is used.
</dd>
<dt><b><i>name</i></b></dt>
<dd>Specify the name of the source file.
</dd>
</dl>
<p><b>Qualifier 2: Library</b>
</p>
<dl>
<dt><b><u>*LIBL</u></b></dt>
<dd>All libraries in the library list for the current thread are searched until the first match is found.
</dd>
</dl>
<dl>
<dt><b>*CURLIB</b></dt>
<dd>The current library for the job is searched. If no library is specified as the current library for the job, the QGPL library is used.
</dd>
<dt><b><i>name</i></b></dt>
<dd>Specify the name of the library to be searched.
</dd>
</dl>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<div> <a name="STRQMPRC.RDB"></a>
<h3>Relational database (RDB)</h3>
<p>Specifies the relation database that is accessed during the processing of this command.
</p>
<dl>
<dt><b><u>*NONE</u></b></dt>
<dd>The local database is accessed. If the user is connected to a remote database, the connection is reset to local and remains local until completion of this command.
</dd>
<dt><b>*CURRENT</b></dt>
<dd>The relational database to which the user is currently connected is accessed.
</dd>
<dt><b><i>name</i></b></dt>
<dd>Specify the name of the relational database that is accessed. The database must have an entry in the relation database directory.
</dd>
</dl>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<div> <a name="STRQMPRC.RDBCNNMTH"></a>
<h3>Connection Method (RDBCNNMTH)</h3>
<p>Specifies the connection method to use.
</p>
<dl>
<dt><b><u>*DUW</u></b></dt>
<dd>Connections to several relational databases are allowed. Consecutive CONNECT statements to additional relational databases do not result in disconnection of previous connections.
</dd>
<dt><b>*RUW</b></dt>
<dd>Only one connection to a relational database is allowed. Consecutive CONNECT statements result in the previous connections being disconnected before a new connection is established.
</dd>
</dl>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<div> <a name="STRQMPRC.USER"></a>
<h3>User (USER)</h3>
<p>Specifies the user name sent to the remote system when starting the conversation.
</p>
<dl>
<dt><b><u>*CURRENT</u></b></dt>
<dd>The user name associated with the current job is used.
</dd>
<dt><b><i>name</i></b></dt>
<dd>Specify the user name being used for the application requester job.
</dd>
</dl>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<div> <a name="STRQMPRC.PASSWORD"></a>
<h3>Password (PASSWORD)</h3>
<p>Specifies the password to be used on the remote system.
</p>
<dl>
<dt><b><u>*NONE</u></b></dt>
<dd>No password is sent. The user name specified on the USER parameter is not valid if this value is specified.
</dd>
<dt><b><i>character-value</i></b></dt>
<dd>Specify the password of the user name specified on the USER parameter.
</dd>
</dl>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<div> <a name="STRQMPRC.NAMING"></a>
<h3>Naming convention (NAMING)</h3>
<p>Specifies the naming convention used for naming objects.
</p>
<dl>
<dt><b><u>*SYS</u></b></dt>
<dd>The system naming convention is used (name/object-name).
</dd>
<dt><b>*SQL</b></dt>
<dd>The SQL naming convention is used (database-name.object-name). If NAMING(*SQL) is specified, CMDSRCFILE(*LIBL) cannot be specified or allowed as a default value for locating any of the objects specified on other parameters on this command.
</dd>
<dt><b>*SAA</b></dt>
<dd>The SQL naming convention is used (database-name.object-name). If NAMING(*SAA) is specified, CMDSRCFILE(*LIBL) cannot be specified or allowed as a default value for locating any of the objects specified on other parameters on this command.
</dd>
</dl>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<div> <a name="STRQMPRC.ALWQRYDFN"></a>
<h3>Allow information from QRYDFN (ALWQRYDFN)</h3>
<p>Specifies whether query or form information is taken from a query definition (QRYDFN) object when no query management query (QMQRY) or query management form (QMFORM) object can be found using the specified object name. Any information that has to be derived in this way is discarded when the common programming interface (CPI) command in the procedure is completed. No query management objects are created.
</p>
<dl>
<dt><b><u>*NO</u></b></dt>
<dd>The information is not taken from a QRYDFN object.
</dd>
<dt><b>*YES</b></dt>
<dd>The information is taken from a QRYDFN object when the specified QMQRY or QMFORM object is not found.
</dd>
<dt><b>*ONLY</b></dt>
<dd>Information can be derived only from a QRYDFN object. Query management objects are ignored.
</dd>
</dl>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<div> <a name="STRQMPRC.CMDSRCFILE"></a>
<h3>Command source file (CMDSRCFILE)</h3>
<p>Specifies the command source file that query management uses to run a command procedure. A command procedure can only contain query management set commands which can set application variables as well as query management variables that start with the 'DSQ' value.
</p>
<p>The supported DSQ variables are:
</p>
<ul>
<li>DSQCMTLV
</li>
<li>DSQCONFIRM
</li>
<li>DSQOAUTH
</li>
<li>DSQSDBNM
</li>
<li>DSQSRUN
</li>
</ul>
<p><b>Single values</b>
</p>
<dl>
<dt><b><u>*NONE</u></b></dt>
<dd>A command source file is not used. The CMDSRCMBR parameter is ignored.
</dd>
</dl>
<p><b>Qualifier 1: Command source file</b>
</p>
<dl>
<dt><b><i>name</i></b></dt>
<dd>Specify the name of the command source file.
</dd>
</dl>
<p><b>Qualifier 2: Library</b>
</p>
<dl>
<dt><b><u>*LIBL</u></b></dt>
<dd>All libraries in the library list for the current thread are searched until the first match is found.
</dd>
</dl>
<dl>
<dt><b>*CURLIB</b></dt>
<dd>The current library for the job is searched. If no library is specified as the current library for the job, the QGPL library is used.
</dd>
<dt><b><i>name</i></b></dt>
<dd>Specify the name of the library to be searched.
</dd>
</dl>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<div> <a name="STRQMPRC.CMDSRCMBR"></a>
<h3>Source member (CMDSRCMBR)</h3>
<p>Specifies the command source member that query management uses to run a command procedure. A command procedure can only contain query management set commands which set variables that start with the 'DSQ' value.
</p>
<dl>
<dt><b><u>*FIRST</u></b></dt>
<dd>The first member is used.
</dd>
<dt><b><i>name</i></b></dt>
<dd>Specify the name of the command source member.
</dd>
</dl>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<div> <a name="STRQMPRC.ALWDSPLAY"></a>
<h3>Display screens (ALWDSPLAY)</h3>
<p>Specifies the display mode used. The query management session is set to interactive mode if ALWDSPLAY(*YES) is specified. If ALWDSPLAY(*NO) is specified, then the session is set to batch mode. The mode is automatically set to batch when running this command in a batch environment.
</p>
<dl>
<dt><b><u>*YES</u></b></dt>
<dd>Displays are shown when used in an interactive session. This mode allows you to interact with the query management commands in the procedure.
</dd>
<dt><b>*NO</b></dt>
<dd>No displays are shown.
</dd>
</dl>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<hr size="2" width="100%">
<div><h3><a name="STRQMPRC.COMMAND.EXAMPLES">Examples</a> </h3>
<p><b>Example 1: Running a Query Management Procedure</b>
</p>
<p>
<pre>
STRQMPRC SRCMBR(MYPROC) SRCFILE(RPTLIB/PROCFILE)
</pre>
</p>
<p>This command starts the query management procedure stored as the member named MYPROC in the source file named PROCFILE in the RPTLIB library.
</p>
<p><b>Example 2: Taking Information From QRYDFN Objects</b>
</p>
<p>
<pre>
STRQMPRC SRCMBR(MYPROC) SRCFILE(PROCFILE)
ALWQRYDFN(*YES) ALWDSPLAY(*NO)
</pre>
</p>
<p>This command starts the query management procedure stored as the member named MYPROC in the first file named PROCFILE in the library list for the job. Query and form information is allowed to be taken, as needed, from QRYDFN objects when the procedure statements are processed. No reports are shown but they can be printed if the user specifies a print request. Objects are replaced without confirmation if confirmation is not requested by the user. The procedure ends with some errors if processing locates a global variable that is not set or if confirmation was requested before replacing objects that already exist.
</p>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
<hr size="2" width="100%">
<div><h3><a name="STRQMPRC.ERROR.MESSAGES">Error messages</a> </h3>
<p><b><u>*ESCAPE Messages</u></b>
</p>
<dl>
<dt><b>QWM2701</b></dt>
<dd>&amp;1 command failed.
</dd>
<dt><b>QWM2703</b></dt>
<dd>&amp;1 command ended.
</dd>
<dt><b>QWM2707</b></dt>
<dd>*LIBL not allowed when SQL naming applied.
</dd>
<dt><b>QWM2709</b></dt>
<dd>User or password not valid with relational database value.
</dd>
<dt><b>QWM2710</b></dt>
<dd>Password value *NONE only valid with user value *CURRENT.
</dd>
<dt><b>QWM2712</b></dt>
<dd>Character in user name not valid.
</dd>
</dl>
</div>
<table width="100%">
<tr><td align="right"><a href="#STRQMPRC.Top_Of_Page">Top</a></td></tr>
</table>
</body>
</html>