Dump Table Contents (DU)

Command title

Dump Table Contents

Description

This command is used to set up parameters and data to be accessed by the low-level access routine TBACC.

COBOL syntax

MOVE 'DU'                   TO xxxx-COMMAND.
CALL 'TBLBASE' USING        TB-PARM
                            xxxx-COMMAND-AREA
                            TBACC-DEF
                            TABLE-AREA.

C syntax

memcpy( tbCommArea.tbCommand, "DU", 2 );
TBLBASE( &tbParm, &tbCommArea, &tbAccDef, pTableArea );

Parameters

TBACC-DEF

TABLE-AREA

Explanation

The contents of the first N rows of the table are moved to TABLE-AREA, where N equals the COUNT value set by the application in xxxx-COMMAND-AREA. The command is normally followed by a call to TBACC. If ERROR 0 is returned, the TBACC-DEF is returned and can be used directly by the TBACC(DK1T0103) subroutine.

Return value

ERROR 0068 is returned if the requested N rows is smaller than the number of rows in the table. The first N rows are returned even when N is less than the number of rows in the table.

Notes

If this command causes an Implicit Open of the table, the count field is not affected.

The DU command only updates the first 32 bytes of the TBACC DEF parameter (see TBACC-DEF (32 bytes)).

Exceptions

None

See also

tableBASE subroutines—for more information on TBACC

8. COUNT (fullword binary)