Deleting and redefining your data sets
You can use the Delete/Define dialog to create a batch job that deletes and redefines the data sets associated with an IMS database and any logically related databases. When you delete and then redefine the data sets, you are effectively emptying the database, so that you can start again with fresh data. From this point, you can either initialize the database and manually add new segments to it, or you can load data into the uninitialized database.
You can delete/define the data sets associated with the following types of IMS databases:
- HDAM - Hierarchical Direct Access Method
- HIDAM - Hierarchical Index Direct Access Method
- HISAM - Hierarchical Index Sequential Access Method
- SHISAM - Simple Hierarchical Index Sequential Access Method
- HSAM - Hierarchical Sequential Access Method (BSAM or QSAM only)
- SHSAM - Simple Hierarchical Sequential Access Method (BSAM or QSAM)
- DEDB - Data Entry Database (Fast Path)
- PHDAM - Partitioned Hierarchical Direct Access Method (HALDB)
- PHIDAM - Partitioned Hierarchical Index Direct Access Method (HALDB)
To generate the JCL for a job that deletes and redefines your database data sets:
- Ensure that your IMS database has been stopped within
your IMS subsystem.
Note: You cannot delete and redefine data sets while they are in use by the IMS subsystem.
- Select option 3 Utilities from the Primary Option Menu and then option 1 Delete/Define from the Utility Menu. The Delete/Define Entry Panel is displayed.
- In the Subsystem name field, enter the ID of the IMS subsystem that the database whose data sets you want to delete/define is defined in, or if you want to select the required subsystem from a list, enter a subsystem name pattern or leave the field blank.
- In the Database name field, enter the name of the database whose data sets you want to delete and redefine, or if you want to select a database from a list of DBDs, enter a database name pattern or leave the field blank. When the database you specify is logically related to other databases, the Delete/Define also deletes and redefines the data sets of the logically related databases.
- If you selected a database that is not a HALDB and an IMS subsystem
that is not a dynamic allocation only subsystem,
in the Fetch DB dsnames from field:
- Enter
1
if you want the function to delete and redefine the database data sets whose names were saved in your user profile. - Enter
2
if you want the function to delete and redefine the database data sets specified in the DFSMDA dynamic allocation members.
- Enter
- If you want to skip the display of the Database Data Set Specification or the Database Data Set Display panel, enter "/" in the Skip DB data set panel field.
- Press Enter to process the data you entered. According to what you entered on the panel,
one or more of these panels may be displayed in the order they are listed:
- Subsystem Selection panel.
- Displayed when you enter no subsystem name or a subsystem name pattern.
- Displays a list of IMS subsystems defined by the FM/IMS administrator at installation time.
- Database Selection panel.
- Displayed when you enter no database name or a database name pattern.
- Displays a list of the DBDs in the DBD libraries for the specified subsystem.
If the DBD libraries for the subsystem are not fixed, you specify the DBD libraries for the subsystem on the PSB and DBD Data Sets panel (option 0.6.7). If the DBD libraries for the subsystem are fixed, the FM/IMS administrator specifies the DBD libraries for the subsystem at installation time.
On each selection panel that is displayed, enter
S
in the Cmd field adjacent to the item you want to select and press Enter. - Subsystem Selection panel.
- If you did not select the Skip DB data set panel option,
either the Database Data Set Display or the Database Data Set Specification
panel is displayed.
- The Database Data Set Display panel is displayed when a database that is a HALDB or a subsystem that is defined as dynamic allocation only is selected on the Delete/Define Entry panel. This panel displays the names of the database data sets that the Delete/Define deletes and redefines. Verify that the database data sets listed are the ones you want the function to use. To confirm usage of these data sets and to proceed to the next panel in the dialog, press Enter.
- The Database Data Set Specification panel is displayed when a database that is not a
HALDB and a subsystem that is not defined as dynamic allocation only is selected on the
Delete/Define Entry panel. If you selected "User profile" for
the Fetch DB dsnames from
option, it displays the data set names saved in your user profile. If you selected
DFSMDA members for the Fetch DB dsnames from option, it displays the data set
names specified in the DFSMDA dynamic allocation members for the subsystem.
The Database Data Set Specification panel is displayed when the Skip DB data set panel option is not selected, but it is also displayed when the Skip DB data set panel option is selected and one of the following conditions is true:
- FM/IMS fails to obtain all the required data set names from either your user profile or the DFSMDA members.
- One or more of the database data sets does not exist or has an invalid data set organization.
If the displayed data set names are not the ones you want the function to use or no data set names are displayed, enter the data set names that you want the function to use and press Enter. To confirm usage of the displayed data set names and to proceed to the next panel in the dialog, press Enter once more.
- Press Enter. FM/IMS uses the data you specified in the dialog to generate JCL for the Delete/Define job. You can edit the JCL before submitting the job.
Related topics