E@DBFULLDELRNG
Name
The E@DBFULLDELRNG call has the following format:
DN@<Logical>(E@DBFULLDELRNG)
where <Logical> identifies the database file to use to perform the E@DBFULLDELRNG call.
Description
E@DBFULLDELRNG deletes all records in a range.
When this routine deletes a database record, it also deletes all index entries associated with that record and any related records according to the following delete rules as set in the database file definition.
Delete Rule | Description |
---|---|
Delete Ignored | No deletion of related records. |
Delete Restrict | Related records must be deleted or moved first by the application. |
Delete Cascades | Delete all records in the related table described by the relation. |
For more information on data deletion rules, see the Application Development Workbench Standards guide
Using the API in a Program
You must populate the delimiting D@ fields and E@DBBEGRNG before using E@DBFULLDELRNG. In recoverable database environments, E@DBFULLDELRNG cannot span more than one transaction state. Deleting a very large range of records in a single block creates a very large journal, or transaction, that might exceed a limit. If a range does not realistically fit in a single transaction, you must use a modify/delete loop, with specific attention paid to controlling the size of the logical transactions.
Input Values
Field | Description |
---|---|
<Logical> | You must specify the database index name that you want to create a record in. |
Record retrieval variables (also known as D@ fields) |
You must populate the index key fields used to locate the record before using this call. Fill in only the D@ fields that define the appropriate range; leave empty those D@ fields that do not define the range. |
E@DBBEGRNG | Move a number into E@DBBEGRNG in order to tell the interface which key is the last significant one defining the range. This number is equivalent to the position of the field in the index. |
Programming Example
The following example shows the E@DBFULLDELRNG routine used to drop a range of records from a file.
|