Previous Topic: Example 2: Deleting User SessionsNext Topic: Example 4: Deleting Profile Sessions


Example 3: Deleting Profiles

You can use the DELETE statement with an extract file to delete a set of profile records. For example, an administrator wants to delete three profiles that have been replaced by other profiles. The administrator uses the following command statements to delete the profiles.

EXTRACT GIVING(DELPROF) PROFILE AND NO SESSIONS 
                        (PIDXNAME(ACCTPROF SERVPROF TSPROF)) 
DELETE PROFILE USING(DELPROF)

The EXTRACT statement produces the extract file named DELPROF, which contains the profile records for each profile in the list of extraction criteria. The DELETE statement deletes the profile records and profile session records for each profile.