Previous Topic: ParametersNext Topic: Examples


Usage

DELETE Deletes Area From Subschemas Associated With Schema

DELETE AREA deletes the named area description from the data dictionary. Consequently, the area is removed not only from the current schema, but also from the descriptions of all subschemas associated with the current schema.

SAME AS AREA clause saves coding time

Because SAME AS AREA copies an existing description, it can relieve the DBA of a considerable amount of coding, particularly when many database procedure calls are common across schemas. For an example of assigning database procedures to areas, see the CALL clause, later in this discussion.

You can code multiple CALL statements

Any number of CALL statements for as many DML functions as desired can be specified for an area, as shown in the following example:

add area name is ins-prod-region
    same as area ins-demo-region of schema empschm version 1
    call excrash before ready for exclusive
    call securchk before ready for protected update
    call updimsg on error during ready for update
    call countall after finish
    call securlog after ready for update.

If more than one BEFORE, AFTER, or ON ERROR procedure is specified for the same function, the procedures are executed in the order specified.

Must respecify all calls to change one call

To change database procedures for an area, all calls must be respecified. For example, to remove CALL SECURLOG from the above specification, code the following:

mod area name is ins-prod-region
    call countall after finish
    call securchk before ready for update.
    call updimsg on error during ready for update
    call excrash before ready for exclusive.

Calls needed for IDMSCOMP compression

If any record in the area uses IDMSCOMP and IDMSDCOM for compression and decompression, the area should have the following database procedure specifications:

call idmscomp before finish
call idmsdcom before finish

This ensures that the work areas used by the compression and decompression routines are freed when a rununit terminates.