DELETE

Use

DELETE ( <table > ).

DELETE ( <row> ).

The DELETE command deletes one row, or all the rows, of a table parameter. The table can be a field of a complex structure. After the DELETE command has been executed, &TFILL contains the current number of rows.

See also INSERT and APPEND.

Delete Complete Table

When you use DELETE on the entire table, all rows are deleted. The value of &TFILL is 0.

Delete Table Row

You specify the index of the row to be deleted – for example, SPFLI_TAB[2]. All higher indexes are reduced by 1 – for example, index 3 becomes index 2.

Example

Here, we use a table parameter with parameter reference SPFLI[].

DELETE ( SPFLI_TAB[2] ).

LOG ( &TFILL ).

LOG ( SPFLI_TAB ).

DELETE ( SPFLI_TAB[2] ).

LOG ( &TFILL ).

LOG ( SPFLI_TAB ).