Previous Topic: RESET PREFIXNext Topic: SCROLL


RESTORE

Use the RESTORE function to replicate a CA Datacom/DB Model or CA FILE Model structure or substructure in PROD status or HIST status to a TEST status. Use this function only with structures and substructures that are in PROD status or HIST status.

You can use the RESTORE function for DATABASE, AREA, TABLE, FILE, RECORD, and DATAVIEW structures and substructures. KEY and ELEMENT substructures must be restored by restoring the entire TABLE or RECORD

Important! We recommend that you restore the structure or substructure from PROD status immediately before you change it to avoid any loss of information.

When you submit a RESTORE function, the DDD-SYNCH attribute value is set to N for all tables in the structure. If a subsequent COPY to PROD status is issued at the database level, all tables are DDD-SYNCH=N instead of just the modified table(s). This results in all plans associated with the tables being flagged invalid. All plans must then be rebound, either manually or automatically when next referenced. To eliminate unnecessary rebinds, copy only the modified tables back to PROD status. Only the plan using these tables requires rebind.

Exceptions for User-Defined Relationships

User-defined relationships with occurrences outside the structure are not restored with the structure or substructure. For more information about adding and maintaining relationship definitions, see the CA Datacom Datadictionary User Guide or see the person responsible for CA Datacom Datadictionary administration at your site.

How it Works

When you restore a TEST structure or substructure, the existing structure or substructure is entirely replaced by the structure or substructure from which it is being restored. Any occurrences or relationships are deleted or added as necessary to make the restored structure or substructure the same as the one from which it is being restored.

When you restore a HIST status structure, you cannot complete the process if any of the occurrences or relationships have been deleted due to exceeding the maximum number of allowed HIST versions.

If you are restoring a substructure (TABLE, FILE, RECORD), the parent entity-occurrence definition must exist in the same version to which you are restoring the substructure. For example, if you are restoring a TABLE substructure to T001 status, the AREA and DATABASE entity-occurrence definitions for that TABLE must exist in T001 status for the RESTORE to be successful.

You can use the date/time stamp (ASOF) to construct a TEST version of what your PROD or HIST status version looked like on that day. Using the date/time stamp, you can determine which structures and substructures were in PROD status at a given time and re-create the structure or substructure in the specified TEST status. After the structure or substructure is restored to the specified TEST status, it can be copied to PROD status.

Note: If your time value includes seconds, round up to the nearest minute.

Use the following format for this command:

Note: If your completed command exceeds the 76 spaces available in one command line, use the prompter panel to issue the command.

►►─┬─ RESTORE ─┬─ entity ─ occ-name ─┬─ STATUS xxxx ─┬────────────────────────►
   └─ RES ─────┘                     └─ STA xxxx ────┘

 ►─┬─ FROM STATUS xxxx ─┬─┬──────────────────────────┬────────────────────────►
   └─ FROM STA xxxx ────┘ └─ AS ─ OF ─ YYYYMMDDhhmm ─┘

 ►─┬─────────────────┬─┬─────────────────┬────────────────────────────────────►◄
   ├─ PASSWORD xxxx ─┤ ├─ OVERRIDE xxxx ─┤
   └─ PSWD xxxx ─────┘ └─ OVRD xxxx ─────┘
entity

(Required) Specify the entity of the root of the structure or the base of the substructure you are restoring.

Valid Entries in DBMAINT Mode:

DATABASE|BAS AREA|ARA
TABLE|TBL
DATAVIEW|DVW

Valid Entries in FILEMAINT Mode:

FILE|FIL RECORD|REC
DATAVIEW|DVW

Default Value:

(No default)

occ-name

(Required) Specify the name of the root of the structure or the base of the substructure you are restoring.

Valid Entries:

1- to 32-character occurrence name

Default Value:

(No default)

STA xxxx

(Required) Specify the status of the occurrence to which you are restoring.

Valid Entries:

T001—T999

Default Value:

(No default)

FROM STA xxxx

(Required) Specify the status of the occurrence from which you are restoring.

Valid Entries:

PROD or 001—997
H000—H997 (000 - 997 is the generation number)
ASOF (if you want to use the AS OF option)

Default Value:

(No default)

AS OF YYYYMMDDhhmm

(Optional) If you enter ASOF in the status field, specify the date/time stamp to display the version of the structure that was in PROD status at that date and time. You can specify the full date and time or a partial date, such as 199001 for the year and month or 19900131 for the year, month and day.

Note: If your time value includes seconds, round up to the nearest minute.

Valid Entries:

1 to 12 digits

Default Value:

(No default)

PSWD xxxx

Only required if this occurrence has password protection against unauthorized maintenance. Supply the password for this occurrence.

Valid Entries:

1- to 4-character password

Default Value:

(No default)

OVRD xxxx

Only required if this occurrence is restricted from unauthorized maintenance or retrieval with a lock level assignment. Supply the override code.

Valid Entries:

1- to 4-character override code

Default Value:

(No default)

When you press PF9 (APPLY), CA Datacom Datadictionary responds with a message confirming successful completion of the function.