HP 3000 Manuals

JOBINFO [ MPE/iX Intrinsics Reference Manual ] MPE/iX 5.0 Documentation


MPE/iX Intrinsics Reference Manual

JOBINFO 

NM and CM callable.

Returns information about any current job or session under your user name
and account.  If you have sufficient capabilities, it returns information
about jobs or sessions running under other users and accounts.

Syntax 
_______________________________________________
|                                             |
|              I16V  I32   U16A               |
|     JOBINFO(jsind,jsnum,jsstatus            |
|               I16V    *    I16              |
|            [,itemnum,item,itemerror] [...]);|
_______________________________________________

            


NOTE You can specify up to five itemnum/item/itemerror triples.
Parameters jsind 16-bit signed integer by value (required) Indicates whether jsnum denotes a session or job: Value Meaning 1 jsnum is a session 2 jsnum is a job jsnum 32-bit signed integer by reference (required) Passes the job/session number for which information is requested. Job/session numbers can be displayed by the SHOWME and SHOWJOB commands. If this value is zero, JOBINFO returns information about your logon job/session (unless the first itemnum has a value of 1; see below). When you pass a 0 for jsnum, JOBINFO returns the actual job/session number in jsnum. jsstatus 16-bit unsigned integer array (required) Returns indicator of the success or failure of the call in a two-element array. The first element contains the error indicator. The second element should be ignored. Value Meaning 0 Successful call. All itemerrors equal zero. 1 Partially successful call. One or more itemerror(s) returned with nonzero values. 2 Unsuccessful call. All itemerrors returned with nonzero values. 3 Unsuccessful call. Syntax error in calling sequence. 4 Unsuccessful call. Unable to retrieve jsnum. 5 Process terminated. The process terminated during the start of retrieval. itemnum 16-bit signed integer by value (optional) Specifies which item value is to be returned. Refer to Table 4-20 for a complete list of valid item numbers and what they return to the caller. item type varies (optional) A reference parameter (whose data type corresponds to the data type for the desired information) to which the desired information is returned. These are standard data types and are defined in Table 2-1. All itemnum and item parameters are output parameters. The only exception is itemnum=1, when all the following conditions are met: * The caller passes itemnum=1 in the first item triple. * The item parameter contains a character string of the form [jsname,]username.acctname. * The jsnum parameter is set to 0, and the jsind parameter is set to 1 or 2. If all these conditions are met, JOBINFO returns information about the specified job/session in all other items and returns that job/session number in jsnum. The size of the first item is determined by the way it is used. itemerror 16-bit signed integer by reference (optional) Returns the success or failure of the retrieval of each item. The returned values are: Value Meaning 0 Successful 1 Invalid itemnum 2 Information requested not valid for specified jsnum 3 Insufficient capability 4 Information not available Table 4-24. JOBINFO Itemnum/Item Values ----------------------------------------------------------------------------------------------- | | | | | Itemnum | Mnemonic | Item Description | | | | | ----------------------------------------------------------------------------------------------- | | | | | 1 | CA | [jsname,]user.account. | | | | | | | | Can be used as an I/O parameter: | | | | | | | | * If used as an input parameter, the array must be 26 bytes | | | | long, plus one for a binary 0 (zero) terminator. The input | | | | string must be in the form [jsname,]user.account. The | | | | wildcard character @ is not allowed. | | | | | | | | * If used as an output parameter, the array must be 26 bytes | | | | long. The output is left-justified and padded with blanks. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 2 | CA8 | Session/job name. | | | | | | | | An ASCII output parameter. Output is left-justified and padded with | | | | blanks. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 3 | CA8 | User name. | | | | | | | | An ASCII output parameter. Output is left-justified and padded with | | | | blanks. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 4 | CA8 | User logon group. | | | | | | | | An ASCII output parameter. Output is left-justified and padded with | | | | blanks. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 5 | CA8 | User account. | | | | | | | | An ASCII output parameter. Output is left-justified and padded with | | | | blanks. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 6 | CA8 | User home group. | | | | | | | | An ASCII output parameter. Output is left-justified and padded with | | | | blanks. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 7 | I32 | The date/time that is displayed by the :SHOWJOB command. This | | | | date/time is updated whenver a job changes state (SCHED, WAIT, EXEC). | | | | | | | | | | | | Returns a 32-bit signed integer to be used by the FMTCLOCK intrinsic. | | | | For a job, this is the time it enters the WAIT state. | | | | | ----------------------------------------------------------------------------------------------- Table 4-24. JOBINFO Itemnum/Item Values (cont.) ----------------------------------------------------------------------------------------------- | | | | | Itemnum | Mnemonic | Item Description | | | | | ----------------------------------------------------------------------------------------------- | | | | | 8 | U16 | The date/time that is displayed by the :SHOWJOB command. This | | | | date/time is updated whenever a job changes state (SCHED, WAIT, | | | | EXEC). | | | | | | | | Returns a 16-bit unsigned integer to be used by the FMTCALENDAR | | | | intrinsic. For a job, this is the date when it enters the WAIT | | | | state. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 9 | CA8 | Input LDEV/class name. | | | | | | | | An ASCII output parameter. Whatever array the user passes in will be | | | | overwritten with the LDEV/class name, using exactly the number of | | | | characters in the LDEV/class name. The remainder of the array is | | | | left intact; no fill character is used. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 10 | CA8 | Output LDEV/class name. | | | | | | | | An ASCII output parameter. Whatever array the user passes in will be | | | | overwritten with the LDEV/class name, using exactly the number of | | | | characters in the LDEV/class name. The remainder of the array is | | | | left intact; no fill character is used. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 11 | CA | Current job step. | | | | | | | | Returns a maximum of 238 ASCII characters and is the image of the | | | | command currently executing. The array must be long enough for the | | | | expected command image (the length can be obtained from itemnum=34). | | | | | ----------------------------------------------------------------------------------------------- | | | | | 12 | I16 | Current number of active jobs | | | | | ----------------------------------------------------------------------------------------------- | | | | | 13 | I16 | Current number of active sessions | | | | | ----------------------------------------------------------------------------------------------- | | | | | 14 | I16 | Job input priority | | | | | ----------------------------------------------------------------------------------------------- | | | | | 15 | I32 | Job/session number | | | | | ----------------------------------------------------------------------------------------------- | | | | | 16 | I16 | Jobfence | | | | | ----------------------------------------------------------------------------------------------- | | | | | 17 | I16 | Job output priority | | | | | ----------------------------------------------------------------------------------------------- | | | | | 18 | I16 | Number of copies | | | | | ----------------------------------------------------------------------------------------------- | | | | | 19 | I16 | Job limit (system) | | | | | ----------------------------------------------------------------------------------------------- | | | | | 20 | I16 | Session limit (system) | | | | | ----------------------------------------------------------------------------------------------- | | | | | 21 | I16 | Job deferred. Returns the values: | | | | | | | | 0 No | | | | 1 Yes | | | | | ----------------------------------------------------------------------------------------------- | | | | | 22 | U16 | Main CI PIN for job/session | | | | | ----------------------------------------------------------------------------------------------- | | | | | 23 | U16 | Original job spooled. | | | | | | | | Returns the values: | | | | | | | | 0 No | | | | 1 Yes | | | | | ----------------------------------------------------------------------------------------------- Table 4-24. JOBINFO Itemnum/Item Values (cont.) ----------------------------------------------------------------------------------------------- | | | | | Itemnum | Mnemonic | Item Description | | | | | ----------------------------------------------------------------------------------------------- | | | | | 24 | U16 | RESTART option. | | | | | | | | Returns the values: | | | | | | | | 0 No | | | | 1 Yes | | | | | ----------------------------------------------------------------------------------------------- | | | | | 25 | U16 | Sequenced job. | | | | | | | | Returns the values: | | | | | | | | 0 No | | | | 1 Yes | | | | | ----------------------------------------------------------------------------------------------- | | | | | 26 | U16 | Term code. | | | | | | | | Returns the values: | | | | | | | | 0 Regular terminal | | | | 1 Regular terminal with special logon | | | | | ----------------------------------------------------------------------------------------------- | | | | | 27 | U16 | CPU limit | | | | | ----------------------------------------------------------------------------------------------- | | | | | 28 | U16 | Session/job state. | | | | | | | | Returns the values: | | | | | | | | 2 Executing | | | | 4 Suspending | | | | 32 Wait | | | | 48 Initialization | | | | 56 Scheduled | | | | | ----------------------------------------------------------------------------------------------- | | | | | 29 | U32 | User's local attributes | | | | | ----------------------------------------------------------------------------------------------- | | | | | 30 | I16 | $STDIN spoolfile number. | | | | | | | | Returns data for current jobs and sessions only. Valid for spoolfile | | | | numbers less than or equal to 32768. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 31 | I16 | $STDIN spoolfile status. | | | | | | | | Returns data for current jobs and sessions only. Returns the values: | | | | | | | | | | | | 0 Open | | | | 1 Active | | | | 3 Reserved | | | | 4 Ready | | | | | ----------------------------------------------------------------------------------------------- | | | | | 32 | I16 | $STDLIST spoolfile number. | | | | | | | | Returns data for current jobs and sessions only. Valid for spoolfile | | | | numbers less than or equal to 32768. | | | | | ----------------------------------------------------------------------------------------------- Table 4-24. JOBINFO Itemnum/Item Values (cont.) ----------------------------------------------------------------------------------------------- | | | | | Itemnum | Mnemonic | Item Description | | | | | ----------------------------------------------------------------------------------------------- | | | | | 33 | I16 | $STDLIST spoolfile status. | | | | | | | | Returns data for current jobs and sessions only. Returns the values: | | | | | | | | | | | | 0 Active | | | | 1 Ready | | | | 2 Open | | | | 3 Reserved | | | | | ----------------------------------------------------------------------------------------------- | | | | | 34 | I16 | Length of itemnum=11 (current job step) | | | | | ----------------------------------------------------------------------------------------------- | | | | | 35 | U16 | SET STDLIST=DELETE invoked. Returns the values: | | | | | | | | 0 $STDLIST is saved | | | | 1 SET STDLIST=DELETE is invoked | | | | | ----------------------------------------------------------------------------------------------- | | | | | 36 | U16 | Job information table data segment number | | | | | ----------------------------------------------------------------------------------------------- | | | | | 37 | N/A | Not allowed. Call results in error to calling routine | | | | | ----------------------------------------------------------------------------------------------- | | | | | 38 | I32 | $STDIN spoolfile number. | | | | | | | | Returns data for current jobs and sessions only. Valid for all | | | | spoolfile numbers regardless of size. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 39 | I32 | $STDLIST spoolfile number. | | | | | | | | Returns data for current jobs and sessions only. Valid for all | | | | spoolfile numbers regardless of size. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 40 | U16 | Session quiet mode. | | | | | | | | Returns: | | | | | | | | 0 No | | | | 1 Yes | | | | | ----------------------------------------------------------------------------------------------- | | | | | 41 | I32 | The job or session number of the job submitter. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 42 | CA8 | The job or session name of the job submitter. | | | | | | | | An ASCII output parameter. Output is left justisfied and padded with | | | | blanks. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 43 | CA8 | The user name of the job submitter. | | | | | | | | An ASCII output parameter. Output is left justified and padded with | | | | blanks. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 44 | CA8 | The user account of the job submitter. | | | | | | | | An ASCII output parameter. Output is left justified and padded with | | | | blanks. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 45 | CA8 | The logical device of the job submitter. | | | | | | | | An ASCII output parameter. Output is left justified and padded with | | | | blanks. | | | | | ----------------------------------------------------------------------------------------------- Table 4-24. JOBINFO Itemnum/Item Values (cont.) ----------------------------------------------------------------------------------------------- | | | | | Itemnum | Mnemonic | Item Description | | | | | ----------------------------------------------------------------------------------------------- | | | | | 46 | U16 | The date/time that the STREAM command was submitted by the job | | | | submitter. For jobs, this is the date that the job was streamed (and | | | | is the same date that appears in the job submitter banner.) For | | | | sessions, this is the date that the session was started via either | | | | the STARTSESS command, the STARTSESS intrinsic, or by the default | | | | automatic logon at boot time. | | | | | | | | This item value differs from item 8 only for jobs scheduled for the | | | | future. | | | | | | | | Returns a 16-bit unsigned integer to be used by the FMTCALENDAR | | | | intrinsic. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 47 | I32 | The date/time that the STREAM command was submitted by the job | | | | submitter. For jobs, this is the time that the job was streamed (and | | | | is the same time that appears in the job submitter banner.) For | | | | sessions, this is the date that the session was started via either | | | | the STARTSESS command, the STARTSESS intrinsic, or by the default | | | | automatic logon at boot time. | | | | | | | | This item value differs from item 7 only for jobs scheduled for the | | | | future. | | | | | | | | Returns a 32-bit signed integer to be used by the FMTCLOCK intrinsic. | | | | | ----------------------------------------------------------------------------------------------- | | | | | 48 | U16 | The job or session type of the job submitter. | | | | | -----------------------------------------------------------------------------------------------
NOTE Unless otherwise indicated, all mnemonics are as defined in Table 2-1.
Operation Notes System manager (SM) or account manager (AM) capability is required to retrieve information about jobs and sessions not logged under your user and account. AM capability restricts access to account session and job information; SM capability allows access to all session and job information. This intrinsic does not alter the condition code. Related Information Intrinsics JOBINFO Commands SHOWJOB, SHOWME, SHOWOUT, SHOWIN Manuals Getting System Information Programmer's Guide (32650-90018)


MPE/iX 5.0 Documentation