Eddy_G

CA Tuesday Tip: (CA IDMS) Deleting unused elements in the dictionary

Discussion created by Eddy_G Employee on Apr 23, 2013
Latest reply on Aug 14, 2013 by Gary_Cherlet
CA IDMS Tuesday Tip by Ian Hill, Principal Support Engineer for April 23, 2013.

The following SQL statement can be used to generate IDD delete statements for all unused elements in a dictionary.

“Unused” meaning elements that are neither in a record nor subordinate to a group field.

SET SESSION CURRENT SCHEMA APPLDICT;
SELECT 'DELETE ELEMENT ''' || E1.INQ_NAM_058 || ''' VERSION ' ||
CAST(E1.ELEM_VER_058 AS CHAR(4)) || '.'
FROM "INQ-058" E1
WHERE NOT EXISTS (
SELECT E2.INQ_NAM_058, E2.ELEM_VER_058
FROM "INQ-058" E2, "ELEMNEST-087" N2
WHERE E2.INQ_NAM_058=E1.INQ_NAM_058
AND E2.ELEM_VER_058=E1.ELEM_VER_058
AND "ELEMNEST-IMPL")
AND NOT EXISTS (
SELECT E3.INQ_NAM_058, E3.ELEM_VER_058
FROM "INQ-058" E3, "SDR-042" R3
WHERE E3.INQ_NAM_058=E1.INQ_NAM_058
AND E3.ELEM_VER_058=E1.ELEM_VER_058
AND "INQ-SDR");


APPLDICT is the SQL schema defined for your network dictionary. it is defined like this:

CREATE SCHEMA APPLDICT
FOR NONSQL SCHEMA SYSDIRL.IDMSNTWK VERSION 1
DBNAME APPLDICT;

Outcomes