z/OS ISPF Services Guide
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


TBBOTTOM—set the row pointer to bottom

z/OS ISPF Services Guide
SC19-3626-00

The TBBOTTOM service sets the current row pointer (CRP) to the last row of a table and retrieves the row unless the NOREAD parameter is specified.

If NOREAD is not specified, all variables in the row, including key, name, and extension variables, if any, are stored in the corresponding dialog variables. A list of extension variable names can also be retrieved.

Command invocation format

Read syntax diagramSkip visual syntax diagram
>>-ISPEXEC--TBBOTTOM--table-name--+--------------------+-------->
                                  '-SAVENAME(var-name)-'   

>--+-------------------+--+--------+--+--------------------+---><
   '-ROWID(rowid-name)-'  '-NOREAD-'  '-POSITION(crp-name)-'   

Call invocation format

Read syntax diagramSkip visual syntax diagram
>>-CALL--ISPEXEC--(buf-len,--buffer);--------------------------><

or

Read syntax diagramSkip visual syntax diagram
>>-CALL--ISPLINK--('TBBOTTOM'--,--table-name--,-+-var-name-+---->
                                                '-'b'------'   

>--,-+-rowid-name-+--,-+-'NOREADbb'-+--,-+-crp-name-+-);-------><
     '-'b'--------'    '-'b'--------'    '-'b'------'      

Parameters

table-name
Specifies the name of the table to be used.
var-name
Specifies the name of a variable where a list of extension variable names contained in the row will be stored. The list is enclosed in parentheses, and the names within the list are separated by a blank.
rowid-name
Specifies the name of a variable in which a number that uniquely identifies the row being accessed is to be stored. Later, this identifier can be specified in the ROW parameter of TBSKIP to cause the CRP to be positioned to the row. This identifier is not saved on permanent storage by TBSAVE or TBCLOSE. The variable must be an 8-byte character field.
NOREAD
Specifies that the variables contained in the requested row are not to be read into the variable pool.
crp-name
Specifies the name of a variable in which the row number pointed to by the CRP is to be stored. If the CRP is positioned to TOP, the row number returned is zero.
buf-len
Specifies a fullword fixed binary integer containing the length of "buffer".
buffer
Specifies a buffer containing the name of the service and its parameters in the same form as they would appear in an ISPEXEC call for a command procedure.

Return codes

These return codes are possible:
 0
Normal completion.
 8
Table is empty; CRP set to TOP (zero).
12
Table is not open.
16
Variable value has been truncated or insufficient space provided to return all extension variable names.
20
Severe error.

Example

Move the current row pointer (CRP) of the table TELBOOK to the last row of the table. From this row, store variable values into the respective function pool variables having the same names.
ISPEXEC TBBOTTOM TELBOOK
Set the program variable BUFFER to contain:
TBBOTTOM TELBOOK
Set program variable BUFLEN to the length of the variable BUFFER. Issue the command:
CALL ISPEXEC (BUFLEN, BUFFER);

or alternately

CALL ISPLINK ('TBBOTTOM','TELBOOK ');

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014