

Modifying Schema Entities › Set Modifications › Adding or Deleting a Set
Adding or Deleting a Set
What components are affected
The schema set definition and data are affected. Segments and DMCLs may also be affected if a set is indexes and a symbolic index specification needs to be added, removed, or replaced in the physical definition. Subschemas and access modules that reference either the owner or member of the set are also affected.
Steps to add or delete a set
To add or delete a set when data has been loaded:
- Create a new schema based on the original schema but containing the new set or omitting the deleted set
- Validate the schema
- Create a global subschema for the new schema
- Use the schema compare utility (IDMSRSTC) to generate the IDMSRSTT macro statements
- Restructure the database using the RESTRUCTURE utility statement
- If adding a set, write a program to connect member record occurrences to the appropriate owner occurrences.
- Complete the change by updating the original schema, regenerating affected subschemas, and altering affected access modules.
Considerations
- Both records participating in a new set must be defined to the schema
- If you replace an existing set with a new set, do not use the AUTO parameter; specify the actual pointer positions. This eliminates the possibility that the schema compiler will identify different pointer positions than exist in the loaded database.
- When deleting an existing set from a schema and a participating record contains pointer positions for sets beyond the deleted set's pointer positions, you must renumber the remaining positions. You cannot leave unused pointer positions.
- If you delete a set, the set is also deleted from all subschema descriptions.
- If you delete the owner record within a set, the set is automatically deleted and both the set and deleted record are removed from all subschema descriptions.
- If you delete the member record within a set, the set remains. You receive an error on validation if there are no remaining members in the set (as in a multimember set)
- If you want a new set to be included in a subschema, you must modify the subschema and add the set to the subschema.
- Regenerating affected subschemas will remove a deleted set from all subschemas.
- When you delete a set, alter and recompile all programs that use the set
Copyright © 2014 CA.
All rights reserved.
 
|
|