In addition, you can direct the RMU Extract command to produce output for the following:
The RMU Extract command decodes information and reconstructs equivalent commands in the language you select with the Language qualifier for the definition of that database.
You can extract the definitions to either a file or to SYS$OUTPUT.
The RMU Extract command extracts the following character set information:
- For databases:
- The database default character set
- The national character set
- For domains:
- The character set of each character data type domain
- The length in characters of each character data type domain
- For tables:
- The character set of each character data type column
- The length in characters of each character data type column
The RMU Extract command encloses all object names in double quotation marks to preserve the uppercase and lowercase characters.
root-file-specThe file specification for the database root file from which you want to extract definitions. Note that you do not need to specify the file extension. If the database root file is not found, the command exits with a "file not found" error.
Items[=item-list]Allows you to extract and display selected definitions. Note that each of the item names can be combined to provide shorter command lines such as the following:$ RMU/EXTRACT/NOLOG/ITEMS=(ALL,NODATABASE) MF_PERSONNEL
If you omit the Items qualifier from the command line or specify it without any options, the action defaults to Items=All.
The following options can be specified with the Items qualifier:
Indicates that all database items are to be extracted. This is the default and includes all items except Alter_Database, Import, Load, Protections, Security, Unload, Verify, and Volume options. You can use either All or Noall in combination with other items to select specific output.
In the following example, the Items=All option causes all the definitions except for Triggers to be extracted and displayed:$ RMU/EXTRACT/ITEMS=(ALL,NOTRIGGERS) MF_PERSONNEL
The following example displays domain and table definitions. Note that the Noall option could have been omitted:$ RMU/EXTRACT/ITEMS=(NOALL, DOMAIN, TABLE) MF_PERSONNEL
- Alter_Database (or Change_Database)
Displays the physical database after-image journal object definition. Each line of the output is prefaced with comment tags if you specify LANGUAGE=RDO.
Displays all contents of the catalog created for an SQL multischema database. This item is ignored if the interface is RDO.
Displays all the collating sequences defined for the database that you select. Note that Oracle Rdb does not save the name of the source OpenVMS National Character Set (NCS) library and the name becomes the defined logical, NCS$LIBRARY, by default.
Displays constraint definitions for the database you select. Table constraints are the output of the Items=Table qualifier; they are not generated by this command.
Displays the database attributes and characteristics. This includes information such as the database root file name, the number of buffers, the number of users, the repository path name, and the characteristics for each storage area.
If you specify RMU Extract with the Option=Nodictionary_References qualifier, the data dictionary path name is ignored. Because the data dictionary is not currently available on Digital UNIX, you might use the Option=Nodictionary_References when you want to extract definitions from a database on OpenVMS for use on Digital UNIX.
- Domains (or Fields)
Displays the domain definitions. If the domain was originally defined using the data dictionary path name, the output definition shows this. If the Option=Nodictionary_References qualifier is specified, the data dictionary path name is ignored and the column attributes are extracted from the system tables.
Displays external function definitions.
Generates an RDO or SQL IMPORT script that defines every storage area and row cache. The Language qualifier determines whether Oracle RMU generates an RDO or SQL IMPORT script (If you specify the Language=SQL or the Language=ANSI_SQL qualifier, the same SQL IMPORT script is generated.) Because the RDO interface does not accept many of the database options added to recent versions of Oracle Rdb, Oracle Corporation recommends that you specify the Language=SQL qualifier (or accept the default).
The Items=Import qualifier is useful when you want to re-create a database that is the same or similar to an existing database. Editing the file generated by Oracle RMU file to change allocation parameters or add storage areas and so on is probably easier than writing your own IMPORT script from scratch.
When Oracle RMU generates the IMPORT script, it uses an interchange file name of rmuextract_rbr in the script. Therefore, you must either edit the IMPORT script generated by Oracle RMU to specify the interchange file that you want to import, or assign the logical name RMUEXTRACT_RBR to your interchange file name. (An interchange file is created by an SQL or RDO EXPORT statement.) See Example 14 in the Examples section.
- Indexes (or Indices)
Displays index definitions, including storage map information.
Generates a DCL command procedure containing an RMU Load command for each table in the database. This item must be specified explicitly, and is not included by default when you use the Items=All qualifier.
See also the Unload option description.
Displays stored procedure and function definitions. This item is valid only when the Language specification is SQL; it is ignored if the Language specification is RDO or ANSI_SQL.
Displays query outline definitions. This item is valid only when the Language specification is SQL; it is ignored if the Language specification is RDO or ANSI_SQL.
Extracts external procedures.
Displays the protection access control list (ACL) definitions. If the protections are defined using SQL ANSI semantics, they cannot be represented in RDO. In this case, the diagnostic message warns you that the protections must be extracted using the Language=SQL qualifier. If you specify Language=ANSI_SQL, a diagnostic message warns you that the ACL-style protections cannot be extracted in ANSI format. You must explicitly specify the Protections option. It is not included by default when you use the Items=All qualifier.
Displays the schema definitions for an SQL multischema database. This option is ignored if the interface is RDO.
Displays RMU Audit commands based on information in the database. This item must be specified explicitly, and is not included by default when you use the Items=All qualifier.
Displays storage map definitions, including the list (segmented string) storage map.
- Tables (or Relations)
Displays table definitions in the same order in which they were created in the database.
If the table was originally defined using the data dictionary path name, that path name is used for the definition.
If you specify the Option=Nodictionary_References qualifier, the data dictionary path name is ignored and the table attributes are extracted from the system tables.
The Items=Tables qualifier handles domains in the following ways:
- The output for this item reflects the original definitions. If a column is based on a domain of a different name, the BASED ON clause is used in RDO, and the domain name is referenced by SQL.
- Any columns that are based on fields in a system table are processed but generate warning messages, as system table fields are not supported.
- Certain domains created using RDO in a relation definition cannot be extracted for RDO because it is not possible to distinguish columns defined using a shorthand method as shown in the example that follows. In this case, the column FIELD_1 becomes or is defined as a domain.DEFINE RELATION REL1. FIELD_1 DATATYPE IS TEXT SIZE 10. END.
However, this type of definition in SQL causes special domains to be created with names starting with SQL$. In this case, the SQL domain is translated into the following data type:CREATE TABLE TAB1 (COLUMN_1 CHAR(10));
The output for this item also includes the table-level constraints that can be applied: PRIMARY KEY, FOREIGN KEY, NOT NULL, UNIQUE, and CHECK. In the case of the CHECK constraint, the expression might not be translated to or from RDO and SQL due to interface differences.
Displays trigger definitions.
Generates a DCL command procedure containing an RMU Unload command for each table in the database.
The Unload option must be specified explicitly. It is not included by default when you use the Items=All qualifier.
See also the Load option description.
Causes the generation of an optimal DCL command procedure containing multiple RMU Verify commands. Using this command procedure is equivalent to performing a full verification (RMU Verify with the All qualifier) for the database. This command procedure can be broken down further into partial command scripts to perform partial verify operations. These partial command scripts can then be submitted to different batch queues to do a full verify operation in parallel, or they can be used to spread out a full verify operation over several days by verifying a piece of the database at a time.
A partitioning algorithm is a procedure to determine what portions of the database should be verified in the same command script. For example, areas with interrelations should be verified with the same partial command script. A partitioning algorithm considers the following when creating a partial command script from the equivalent RMU Verify command with the All qualifier:
- Each storage area is assigned to a partition.
- For each table in the database, if the table is not partitioned, the table is put in the partial command script corresponding to that storage area; otherwise, if the table is partitioned across several storage areas, the partitions corresponding to all of the storage areas are merged into one partial command script and the table is added to this partial command script.
- For each index in the database, the process shown in step 2 is followed.
- For an index on a table, the index and table are merged into one partial command script.
The scripts of partial RMU Verify commands are written in the form of a command procedure. Each partial command script is preceded by a label of the form STREAM_n: where n is an integer greater than 1. For example, to execute the command at label STREAM_3:, invoke the command procedure by using the following syntax:$ @<command-procedure-name> STREAM_3
The resultant command procedure is set up to accept up to four parameters, P1, P2, P3, and P4, as shown in Table 2-9.
Table 2-9 Parameters for Generated Command File Parameter Option Description P1 Stream_n Specifies the command stream to be executed. The variable n is the "number" of the RMU Verify command stream to be executed. If omitted, all command streams are executed. P2 [No]Log Specifies whether to use the Log qualifier in the RMU Verify command line. If omitted, the DCL verify switch value is used. P3 Read_Only | Protected | Exclusive Provides the RMU Verify
Transaction_Type value. If omitted, Transaction_Type = Protected is used.
P4 Specifies the name of the output file for the RMU Verify Output qualifier. If omitted, Output = SYS$OUTPUT is used.
Displays view definitions. If the database was defined using SQL, it is possible that the view cannot be represented in RDO. In this case, the diagnostic message warns that the view definition is being ignored, and the user should use LANGUAGE=SQL to extract the view. Note the following transformations the RMU Extract command makes when it cannot precisely replicate the SQL source code:
- The RMU Extract command cannot precisely replicate derived table column names or correlation names for any select expression.
The RMU Extract command generates new names for correlation names (C followed by a number) and derived table column names (F followed by a number).
For example, suppose you create a view, as follows:SQL> ATTACH 'FILENAME mf_personnel'; SQL> CREATE VIEW DERIVED_1 cont> (F1) AS cont> SELECT CAST(AVG(JOB_COUNT) AS INTEGER(2)) cont> FROM (SELECT EMPLOYEE_ID, COUNT (*) cont> FROM JOB_HISTORY cont> GROUP BY EMPLOYEE_ID) AS EMP_JOBS (EMPLOYEE_ID, JOB_COUNT); SQL> COMMIT;
If you issue the following RMU Extract command, you receive the output shown:$ RMU/EXTRACT/ITEM=VIEWS MF_PERSONNEL.RDB. . . CREATE VIEW DERIVED_1 (F1) AS SELECT CAST(AVG(C2.F2) AS INTEGER(2)) FROM (SELECT C4.EMPLOYEE_ID, COUNT(*) FROM JOB_HISTORY C4 GROUP BY C4.EMPLOYEE_ID) AS C2 ( F1, F2 );
- The RMU Extract command cannot generate the original SQL source code for the user-supplied names of AS clauses. This is particularly apparent when the renamed select expression is referenced in an ORDER BY clause. In such a case, the RMU Extract command generates correlation names in the form RMU$EXT_n where n is a number.
For example, suppose you create a view, as follows:SQL> SET QUOTING RULES 'SQL92'; SQL> CREATE DATA FILE xyz; SQL> CREATE TABLE DOCUMENT cont> (REPORT CHAR(10)); SQL> CREATE TABLE REPORTING cont> (NAME CHAR(5)); SQL> CREATE TABLE "TABLES" cont> (CODTAB CHAR(5)); SQL> CREATE VIEW VIEW_TEST cont> (CREDIT, cont> CODTAB, cont> CODMON) AS cont> SELECT cont> C1.NAME, cont> C2.CODTAB, cont> (SELECT C7.REPORT FROM DOCUMENT C7) AS COM cont> FROM REPORTING C1, "TABLES" C2 cont> ORDER BY C1.NAME ASC, C2.CODTAB ASC, COM ASC; SQL>
If you issue the following RMU Extract command, you receive the output shown:$ RMU/EXTRACT/ITEM=VIEW XYZ.RDB$ rmu -extract -item=view xyz.rdb. . . create view VIEW_TEST (CREDIT, CODTAB, CODMON) as select C1.NAME, C2.CODTAB, (select DOCUMENT.REPORT from DOCUMENT) AS RMU$EXT_1 from REPORTING C1, "TABLES" C2 order by C1."NAME" asc, C2.CODTAB asc, RMU$EXT_1 asc;
Displays cardinality information in a PDL-formatted file for use by Oracle Expert for Rdb. This item must be specified explicitly, and is not included by default when the Items=All qualifier is used.
Language=lang-nameAllows you to select one of the following interfaces:
When you specify the Language=SQL qualifier, Oracle RMU generates the Oracle Rdb SQL dialect. The Oracle Rdb SQL dialect is a superset of SQL92 Entry level, with language elements from Intermediate and Full SQL92 levels. It also contains language elements from SQL3 (which is a draft of a future SQL standard) and extensions specific to Oracle Rdb.
When you specify the Language=ANSI_SQL qualifier and specify the Option=Normal qualifier, Oracle RMU tries to generate ANSI SQL statements that conform to the ANSI X3.135-1989 SQL standard.
When you specify the Language=ANSI_SQL qualifier and the Option=Full qualifier, Oracle RMU tries to generate SQL statements that conform to the ANSI X3.135-1992,ISO 9075:1992 standard (commonly referred to as the ANSI/ISO SQL standard or SQL92).
Regardless of the Option parameter you specify, any Oracle Rdb specific features (such as DATATRIEVE support clauses and storage maps) are omitted.
When you specify the RDO language option, Oracle RMU generates RDO statements.
The default is Language=SQL.
The Language qualifier has no effect on the output generated by the Items=Load, Items=Unload, and Items=Verify qualifiers. This is because these qualifiers generate scripts that contain Oracle RMU commands only.
NologEnable or disables log output during execution of the RMU Extract command. The log includes the current version number of Oracle Rdb, and the values of the parameter and qualifiers. The default is Nolog. The default file extension is .log. If you specify Log without specifying a file name, output is sent to SYS$OUTPUT.
Options=options-listThis qualifier is used to change the output of the RMU Extract command. This qualifier is not applied to output created by the Items=Volume, Items=Unload, Items=Load, Items=Security, or the Items=Verify qualifier.
The following options can be specified with the Options qualifier:
Includes only the specific source language code used to define the database. This is the default.
In addition, this option propagates RDO VALID IF clauses as column CHECK constraints with the attribute NOT DEFERRABLE when the Language specification is SQL or ANSI_SQL. When an RDO VALID IF clause is converted, Oracle RMU generates error messages similar to the following in your log file:%RMU-W-UNSVALIDIF, VALID IF clause not supported in SQL - ignored for DEGREE. %RMU-I-COLVALIDIF, changed VALID IF clause on domain DEGREE to column check constraint for DEGREES.DEGREE
The first message is a warning that the VALID IF clause could not be added to the domain definition because the VALID IF clause is not supported by SQL. The second message is an informational message that tells you the VALID IF clause was changed to a column check constraint. This is the default.
Specifies that if metadata that cannot be translated from the language that defined the database to the equivalent construct in the language specified with the Language qualifier (for example, DEFAULT for SQL and the language selected was RDO) then the metadata is displayed in comments, or Oracle RMU attempts to create a translation that most closely approximates the original construct.
Identical to the Normal option.
Directs the RMU Extract command to output the table, column, and column segmented string cardinalities based on sorted indexes. Note that this qualifier must be used in combination with the Items=Volume qualifier. If the Items=Volume qualifier is omitted, cardinalities are not displayed.
RMU Extract generates data of the following type:Volume for schema MF_PERSONNEL Default volatility is 5; Table WORK_STATUS all is 3; Table EMPLOYEES all is 100; Column EMPLOYEE_ID all is 100; Column LAST_NAME all is 83; . . . Table RESUMES all is 3; List RESUME Cardinality IS 3 Number of segments is 3 Average length of segments is 24;
Dumps the internal representation for SQL clauses such as VALID IF, COMPUTED BY, MISSING_VALUE, DEFAULT_VALUE, CONSTRAINTS, SQL DEFAULT, TRIGGERS, VIEWS, and STORAGE MAPS during processing. The keyword Debug cannot be specified with the keywords Normal or Full in the same Options qualifier list.
Directs the RMU Extract command to output definitions for domains (fields) and tables (relations) that reference data dictionary path names rather than using the information contained in the Oracle Rdb system tables. In addition to the database statements, this option also displays the data dictionary path name stored in the database. Refer to Example 8 in the Examples section for an example of using this option.
Beginning in Oracle Rdb V7.0, the default for this option is changed. If the Option=Dictionary_References qualifier or the Option=Nodictionary_References qualifier is not specified, then Oracle RMU examines the RDB$RELATIONS and RDB$FIELDS system tables to determine whether or not any domains or tables refer to the data dictionary. If references are made to the data dictionary, then the Option=Dictionary_References qualifier is the default. Otherwise, it is assumed that the data dictionary is not used, and the default is the Option=Nodictionary_References qualifier.
Causes all references to the data dictionary to be omitted from the output. This is desirable if the database definition is to be used on a system without the data dictionary (such as Digital UNIX), or in a testing environment.
If the Items=Database and Option=Nodictionary_References qualifiers are selected, the data dictionary path name stored in the system table is ignored. For SQL, the no PATH NAME clause is generated, and for RDO, the clause DICTIONARY IS NOT USED is generated.
If the Items qualifier specifies Domain or Table, and the Option qualifier specifies Nodictionary_References, the output definition includes all attributes stored in the system tables.
Directs the RMU Extract command to perform queries to calculate the cardinality of each table, if both the Items=Volume and Options=Volume_Scan qualifiers are specified. The default is Options=Novolume_Scan, in which case the approximate cardinalities are read from the RDB$RELATIONS system table. The Options=Volume_Scan option is ignored if the Items=Volume qualifier is not selected.
This option is an alias for Dictionary_References.
- Nocdd_Constraints (default)
When you use this option and the Dictionary_References option, the RMU Extract command generates ALTER TABLE statements to add FOREIGN KEY and CHECK constraints after all base tables have been created.
When you specify this option and the Dictionary_References option, the RMU Extract command does not output ALTER TABLE statements to add constraints, but instead assumes they will be inherited from the data dictionary.
Specifies that a full scan for segmented strings should be done.
Specifies the maximum amount of data to be scanned for segmented fields. The RMU Extract command stops scanning when the limit nn is reached. The number of segments and average length of segments are calculated from the data that was scanned. Limit_Volume=1000 is the default.
Specifies the width of the output files. You can select values from 60 to 512 characters. The default of 80 characters is appropriate for most applications.
Displays the SQL multischema names of database objects. Ignored by the Relational Database Operator (RDO).
Displays only the SQL single-schema names of database objects.
Causes all file specifications extracted from the database to be truncated to only the file name. The use of this qualifier allows for easier relocation of the new database when you execute the created procedure.
NooutputNames the file to which the RMU Extract command writes the data definition language (DDL) statements. The file extension defaults to .rdo, if you specify the Language=RDO qualifier; .sql, if you specify either the Language=SQL or the Language=ANSI_SQL qualifier. If you specify the Volume option only, the output file type defaults to .pdl. If you specify Load, Security, Verify, or Unload only, the output file type defaults to .com. The default is SYS$OUTPUT. If you disable the output by using the Nooutput qualifier, command scripts are not written to an output file. The Log output can be used to determine which features used by the database cannot be converted to SQL.
Table 2-10 shows the effects of the various combinations of the Language and Options qualifiers.
|Language||Option||Effect on Output|
|RDO||Normal||Generates RDO syntax.|
|Full||Generates RDO syntax.|
|Outputs path name references to the repository.|
|Converts path name references to the repository to RDO syntax.|
|Multischema||Ignored by RDO.|
|SQL||Normal||Generates SQL syntax.|
|Full||Tries to convert RDO specific features to SQL (for example, the VALID IF clause).|
|Outputs path name references to the data dictionary.|
|Converts path name references to the data dictionary to SQL syntax.|
|Multischema||Selects SQL multischema naming of objects.|
|ANSI_SQL||Normal||Generates ANSI/ISO syntax.|
|Full||Generates ANSI/ISO SQL92 syntax supported by SQL.|
|Ignored for ANSI_SQL.|
|Converts path name references to the data dictionary to SQL syntax. This is the default for ANSI_SQL.|
|Multischema||Selects SQL multischema naming of objects.|
|Any||Debug||Annotates output where possible.|
|Volume_Scan||Forces a true count of Tables. Only valid for Items=Volume.|
|Filename_Only||Truncates all file specifications extracted from the database to only the file name.|
- To use the RMU Extract command for a database, you must have the RMU$UNLOAD privilege in the root file access control list (ACL) for the database or the OpenVMS SYSPRV or BYPASS privilege.
- For tutorial information on using output from the RMU Extract command to load or unload a database, refer to the Oracle Rdb7 Guide to Database Design and Definition.
- The RMU Extract command cannot generate the original SQL source code for GROUP BY select expressions. If your SQL source code contains GROUP BY select expressions, you must add them to the code generated by the RMU Extract command before running this generated code.
- Included in the output from the RMU Extract command is the SQL SET DEFAULT DATE FORMAT statement. This SQL statement determines whether columns with the DATE or CURRENT_TIMESTAMP data type are interpreted as VMS or SQL92 format. The RMU Extract command always sets the default to SQL92. The SQL92 format DATE and CURRENT_TIMESTAMP data types contain only the YEAR TO DAY fields. The VMS format DATE and CURRENT_TIMESTAMP data types contain YEAR to SECOND fields.
If your database was defined with VMS format DATE and CURRENT_TIMESTAMP data types, the default SQL SET DEFAULT DATE FORMAT 'SQL92' in the Extract output causes errors to be returned when you attempt to execute that output. For example, when you define a domain:CREATE DOMAIN TSTAMP DATE VMS DEFAULT CURRENT_TIMESTAMP; %SQL-F-DEFVALINC, You specified a default value for TSTAMP which is inconsistent with its data type
When you define a trigger:SQL> CREATE TRIGGER SALARY_HISTORY_CASCADE_UPDATE cont> AFTER UPDATE OF JOB_CODE ON JOB_HISTORY cont> (UPDATE SALARY_HISTORY SH cont> SET SALARY_START = CURRENT_TIMESTAMP cont> WHERE (SH.EMPLOYEE_ID = JOB_HISTORY.EMPLOYEE_ID) cont> ) for each row; %SQL-F-UNSDATASS, Unsupported date/time assignment from <Source> to SALARY_START
You can avoid these errors by editing the output from the RMU Extract command. Replace the SET DEFAULT DATE FORMAT 'SQL92' statement with SET DEFAULT DATE FORMAT 'VMS'. If the problem occurs in trigger definitions, you can use the CAST function instead. Specify CAST(CURRENT_TIMESTAMP AS DATE VMS) with each trigger definition that references CURRENT_TIMESTAMP. (You cannot use the CAST function within the DEFAULT clause of an SQL CREATE statement).
- The RMU Extract command generates the syntax, NUMBER OF CLUSTER NODES IS, when it encounters either of the following clauses:
- NUMBER OF VAXCLUSTER NODES IS
- NUMBER OF CLUSTER NODES IS
These are optional clauses for the RDO DEFINE DATABASE, CHANGE DATABASE, and IMPORT statements and the SQL CREATE DATABASE, ALTER DATABASE, and IMPORT statements.
- The following list contains a description of what the RMU Extract command generates when it encounters certain RDO statements:
- RDO and the data dictionary have the concept of validation clauses at the domain level. The ANSI/ISO SQL92 standard allows CHECK constraints defined on domains. While the actions of the ANSI/ISO CHECK constraint do differ from VALID IF in some respects, the RMU Extract command extracts the VALID IF clauses as domain CHECK constraints if you specify the Language=SQL and Option=Full qualifiers.
- RDO multiline descriptions
Because the RDO interface removes blank lines in multiline descriptions, the description saved in the metadata is not identical to that entered by the database definition. The RMU Extract command therefore cannot completely reconstruct the original description.
- Some RDO trigger definitions
RDO trigger definitions that contain a trigger action within a join of two or more tables generates invalid SQL syntax. For example, the following RDO trigger definition includes a join with an embedded ERASE statement. When the RMU Extract command encounters this statement, Oracle RMU generates the invalid SQL trigger definition shown.DEFINE TRIGGER EXAMPLE AFTER ERASE FOR C1 IN EMPLOYEES EXECUTE FOR C2 IN JOB_HISTORY CROSS C3 IN EMPLOYEES WITH (((C2.EMPLOYEE_ID = C3.EMPLOYEE_ID) AND (C2.JOB_END MISSING)) AND (C3.EMPLOYEE_ID = C2.EMPLOYEE_ID)) ERASE C2 END_FOR FOR EACH RECORD. CREATE TRIGGER EXAMPLE AFTER DELETE ON EMPLOYEES (DELETE FROM JOB_HISTORY C2, EMPLOYEES C3 WHERE (((C2.EMPLOYEE_ID = C3.EMPLOYEE_ID) AND (C2.JOB_END IS NULL)) AND (C3.EMPLOYEE_ID = C2.EMPLOYEE_ID)) ) FOR EACH ROW;
Note that in Oracle Rdb Version 4.1 and higher, including a trigger action within a join of two or more tables is invalid RDO syntax. For more information on this RDO restriction, see the ERASE and MODIFY entries in RDO HELP.
- Oracle CDD/Repository Version 5.3 and higher support table and column constraint definition and maintenance through CDO. The RMU Extract command, by default, assumes all constraint maintenance is with SQL and so follows each CREATE TABLE with an ALTER TABLE FROM pathname to add the constraints. However, this is no longer necessary if you are using the later versions of Oracle CDD/Repository. To disable the output of the SQL ALTER TABLE statements which add constraints use the Option=Cdd_Constraint qualifier.
- When using the RMU Extract command, you might expect that the output from the command will not contain references to the data dictionary path name (for example: attach 'pathname mypath') unless you are using the data dictionary, or your database is integrated with the data dictionary.
Prior to Oracle Rdb V7.0, by default, the RMU Extract command assumed that you would be using the output it generates with the data dictionary. If that was not your intent, you had to specify the Options=Nodictionary_References qualifier with the RMU Extract command.
Beginning in Oracle Rdb V7.0, if the database being used has no dictionary references, the default is Options=Nodictionary_References. If the database being used does have dictionary references, then the default is Options=Dictionary_References.
The following command extracts these database items: COLLATING_SEQUENCES, DOMAINS, TABLES, INDEXES, STORAGE_MAPS, VIEWS, and TRIGGERS.
The All option is the default. The All or Noall option can be used in conjunction with other items to select specific output. For example, the Items=(All,Nodatabase) qualifier selects all metadata items except the physical database characteristics.$ RMU/EXTRACT/ITEM=(ALL, NODATABASE) MF_PERSONNEL
The following command generates a DCL command procedure containing an RMU Load command for each table in the database:$ RMU/EXTRACT/ITEMS=LOAD MF_PERSONNEL
The following command displays the protection access control list (ACL) definitions in the mf_personnel.rdb database:$ RMU/EXTRACT/ITEMS=PROTECTIONS MF_PERSONNEL.RDB
The following command generates a DCL command procedure containing an RMU Unload command for each table in the database:$ RMU/EXTRACT/ITEMS=UNLOAD MF_PERSONNEL.RDB
The following command displays cardinality information in a PDL-formatted file for use by Oracle Expert for Rdb:$ RMU/EXTRACT/ITEMS=VOLUME MF_PERSONNEL.RDB
The following example displays index definitions:$ RMU/EXTRACT/ITEMS=INDEXES MF_PERSONNEL
The following example displays domain and table definitions. Note that the Noall option could have been omitted.$ RMU/EXTRACT/ITEMS=(NOALL,DOMAINS,TABLES) MF_PERSONNEL
The following example displays definitions for domains (fields) and tables (relations) that reference data dictionary path names rather than using the information contained in the Oracle Rdb system tables. In addition to the database statements, it also references the data dictionary path name stored in the database, as shown in the following example:$ RMU/EXTRACT/LANG=SQL/ITEM=ALL/OPTION=DIC/OUTPUT=CDD_MODEL.LOG/LOG= - _$ CDD_EXTRACT.LOG CDD_SQL_DB
The following example creates a command procedure containing a script of partial RMU Verify commands or verify command partitions for the mf_personnel database. This command procedure was created with the following RMU Extract command:$ RMU/EXTRACT/ITEM=VERIFY MF_PERSONNEL
The following command displays a query outline definition that was previously added to the mf_personnel database:$ RMU/EXTRACT/ITEMS=(OUTLINES) MF_PERSONNEL
The following command displays the after-image journal (.aij) file configuration for mf_personnel:$ RMU/EXTRACT/ITEMS=(ALTER_DATABASE) MF_PERSONNEL
The following command displays the function definitions in mf_personnel for functions previously created using SQL:$ RMU/EXTRACT/ITEM=FUNCTION MF_PERSONNEL
The following command displays the table and column cardinalities based on sorted indexes:$ RMU/EXTRACT/OPTION=COLUMN_VOLUME/ITEM=VOLUME MF_PERSONNEL
The following example:
- Executes an SQL EXPORT statement to create an interchange file.
- Executes an RMU Extract command with the Item=Import qualifier to generate an Import script. In addition, the Option=Filename_Only qualifier is specified to prevent full file specifications from appearing in the SQL IMPORT script. (If full file specifications are used, you cannot test the script without replacing the database that was exported.)
- Defines a logical to define the interchange file name used in the Import script file.
- Executes the Import script file.SQL> -- Create interchange file, SAVED_PERS.RBR. SQL> -- SQL> EXPORT DATABASE FILENAME MF_PERSONNEL.RDB INTO SAVED_PERS.RBR; SQL> EXIT; $ ! $ RMU/EXTRACT/ITEM=IMPORT/OPTION=FILENAME_ONLY/OUTPUT=IMPORT_PERS.SQL - _$ MF_PERSONNEL $ DEFINE/USER RMUEXTRACT_RBR SAVED_PERS.RBR $ ! $ SQL SQL> @IMPORT_PERS.SQL SQL> set language ENGLISH; SQL> set default date format 'SQL92'; SQL> set quoting rules 'SQL92'; SQL> set date format DATE 001, TIME 001; SQL> SQL> -- RMU/EXTRACT for Oracle Rdb V7.0-00 1-JUL-1996 15:34:38.63 SQL> -- SQL> -- Physical Database Definition SQL> -- SQL> --------------------------------------------------------------------- SQL> import database from rmuextract_rbr cont> filename 'MF_PERSONNEL' . . .
Copyright ©1996, Oracle Corporation All rights reserved.