This statement is used to delete accounts from the
SCC-DLimit database. The accounts specified by the
INCLUDE ACCOUNT and EXCLUDE ACCOUNT
filter criteria are deleted.
The ALL or EMPTY operands indicate
whether the account is to be deleted only if the current space amount is
zero (EMPTY), or even if some space is currently assigned
to the account (ALL).
EMPTY).This function requires ALTER authority to each account
name (DSL.acctname) or DLimit database administrator
authority (UPDATE access to DSL.$CONTROL).
ERASE
scope
LIST
scope
Function: This is an optional parameter. This positional
parameter defines the scope of the ERASE function. The
valid options are:
-
ALL— delete accounts even if some space is currently assigned to the account. -
EMPTY— delete accounts only if the current space amount is zero.
Default:
EMPTY
Format:
ALL or EMPTY
LIST
Function: This is an optional parameter. The
LIST operand indicates that the names of the
accounts processed during the ERASE operation are to
be displayed in the SYSPRINT dataset.
Default: None
Format:
LIST
Example The following example shows the use of the
ERASE statement to delete accounts in the
SCC-DLimit database that are currently empty (have
zero space assigned to any space value). Only accounts whose names begin
with the characters 'REGION3' are affected. The active
SCC-DLimit database is not used - instead, a
key-sequenced VSAM cluster that has been previously loaded from a backup
via the RESTORE function is used.
//DSLERASE JOB ...
//DLMAINT EXEC PGM=DLMAINT,REGION=4M
//STEPLIB DD DISP=SHR,DSN=DTS.R71.LOADLIB
//DBFILE DD DISP=SHR,DSN=DSL.KSDS.FILE
//SYSPRINT DD SYSOUT=*
//SYSABEND DD SYSOUT=*
//SYSIN DD *
SET DATABASE(VSAM(DBFILE)) INCLUDE ACCOUNT(REGION3*) ERASE EMPTY LIST