| Oracle DBMS_REGISTRY Version 26ai |
|---|
| General Information | ||||||||||||||||||||||||||||
| Library Note |
|
|||||||||||||||||||||||||||
| Purpose | API for creating and maintaining registry entries. This is one of those undocumented packages where I feel it essential to warn readers that the demos here are for education purposes only. If you run any of them you may totally destroy your database. Oracle Support is likely not going to bail you out and neither will I. | |||||||||||||||||||||||||||
| AUTHID | DEFINER | |||||||||||||||||||||||||||
| Constants |
|
|||||||||||||||||||||||||||
| Data Types | -- Component Hierarchy Type |
|||||||||||||||||||||||||||
| Dependencies | SELECT name FROM dba_dependencies WHERE referenced_name = 'DBMS_REGISTRY' UNIONReturns 51 objects |
|||||||||||||||||||||||||||
| Documented | No | |||||||||||||||||||||||||||
| Exceptions |
|
|||||||||||||||||||||||||||
| First Available | Not known | |||||||||||||||||||||||||||
| Pragmas | SUPPLEMENTAL_LOG_DATA(default, NONE); | |||||||||||||||||||||||||||
| Registry Entries | col comp_id format a9 |
|||||||||||||||||||||||||||
| Registry Log Query | col cid format a12 |
|||||||||||||||||||||||||||
| Security Model | Owned by SYS with EXECUTE granted to CTXSYS, LBACSYS, MDSYS, WMSYS and XDB and the DATAPATCH_ROLE and EXECUTE_CATALOG_ROLE roles. | |||||||||||||||||||||||||||
| Source | {ORACLE_HOME}/rdbms/admin/dbmscr.sql {ORACLE_HOME}/rdbms/admin/prvtcr.plb |
|||||||||||||||||||||||||||
| Subprograms |
|
|||||||||||||||||||||||||||
| CHECK_SERVER_INSTANCE | ||||||||||||||||||||||||||||
| Database must be open for upgrade or downgrade for this to be used | dbms_registry.check_server_instance; |
|||||||||||||||||||||||||||
-- see $ORACLE_HOME/rdbms/admin/cmpupstr.sql |
||||||||||||||||||||||||||||
| COMP_NAME | ||||||||||||||||||||||||||||
| Returns the component name corresponding to a component ID | dbms_registry.comp_name(comp_id IN VARCHAR2) RETURN VARCHAR2; |
|||||||||||||||||||||||||||
desc registry$
PROCEDURE loaded(comp_id IN VARCHAR2) IS |
||||||||||||||||||||||||||||
| COUNT_ERRORS_IN_REGISTRY | ||||||||||||||||||||||||||||
| Returns the number of errors found in the registry for the identified comp_id | dbms_registry.count_errors_in_registry(comp_id IN VARCHAR2) RETURN NUMBER; |
|||||||||||||||||||||||||||
SELECT dbms_registry.count_errors_in_registry('SDO') |
||||||||||||||||||||||||||||
| DELETE_PROGRESS_ACTION | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.delete_progress_action( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| DOWNGRADED | ||||||||||||||||||||||||||||
| Undocumented The demo, at right, is copied from ?/rdbms/admin/dve122.sql. Not present in 18c or above |
dbms_registry.downgraded( |
|||||||||||||||||||||||||||
exec dbms_registry.downgraded('DV', '12.2.0'); |
||||||||||||||||||||||||||||
| DOWNGRADING | ||||||||||||||||||||||||||||
| Undocumented The demo, at right, is copied from ?/rdbms/admin/dve122.sql. Not present in 18c or above |
dbms_registry.downgrading( |
|||||||||||||||||||||||||||
exec dbms_registry_.downgrading('DV'); |
||||||||||||||||||||||||||||
| EDITION | ||||||||||||||||||||||||||||
| Undocumented and appears to not return a value when run in EE | dbms_registry.edition(comp_id IN VARCHAR2) RETURN VARCHAR2; |
|||||||||||||||||||||||||||
SELECT comp_id, comp_name |
||||||||||||||||||||||||||||
| GET_CONTAINER_NAME | ||||||||||||||||||||||||||||
| No matter the input always returns CDB$ROOT. Entered into BugDB for version 23.1 Note: a negative number cannot be a valid con_id: Opened in BugDB |
dbms_registry.get_container_name(con_id IN container$.con_id#%TYPE) |
|||||||||||||||||||||||||||
SELECT dbms_registry.get_container_name(-22); |
||||||||||||||||||||||||||||
| GET_CONT_ID | ||||||||||||||||||||||||||||
| Returns the con_id of the current container | dbms_registry.get_con_id RETURN NUMBER; |
|||||||||||||||||||||||||||
SELECT dbms_registry.get_con_id; |
||||||||||||||||||||||||||||
| GET_DEPENDENT_COMPS | ||||||||||||||||||||||||||||
| Returns a list of dependent components | dbms_registry.get_dependent_comps(comp_id IN VARCHAR2) |
|||||||||||||||||||||||||||
SELECT comp_id, comp_name |
||||||||||||||||||||||||||||
| GET_DEPENDENT_COMPS_REC | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.get_dependent_comps_rec(comp_id IN VARCHAR2) RETURN comp_depend_rec; |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| GET_PROGRESS_STEP | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.get_progress_step( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| GET_PROGRESS_VALUE | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.get_progress_value( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| GET_REQUIRED_COMPS | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.get_required_comps(comp_id IN VARCHAR2) |
|||||||||||||||||||||||||||
SELECT comp_id, comp_name |
||||||||||||||||||||||||||||
| GET_REQUIRED_COMPS_REC | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.get_required_comps_rec( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| INVALID | ||||||||||||||||||||||||||||
| Mark an item in the registry as invalid | dbms_registry.invalid(comp_id IN VARCHAR2); |
|||||||||||||||||||||||||||
col comp_id format a10 |
||||||||||||||||||||||||||||
| IS_COMPONENT | ||||||||||||||||||||||||||||
| Determines whether a component id corresponds with a component | dbms_registry.is_component(comp_id IN VARCHAR2) RETURN BOOLEAN; |
|||||||||||||||||||||||||||
set serveroutput on |
||||||||||||||||||||||||||||
| IS_DB_CONSOLIDATED | ||||||||||||||||||||||||||||
| Returns TRUE if the database is a consolidated database but but this seems to mean a CDB not that it is multi-tenant | dbms_registry.is_db_consolidated RETURN BOOLEAN; |
|||||||||||||||||||||||||||
set serveroutput on |
||||||||||||||||||||||||||||
| IS_DB_PDB | ||||||||||||||||||||||||||||
| Returns TRUE if in a PDB and FALSE if in CDB$ROOT | dbms_registry.is_db_pdb RETURN BOOLEAN; |
|||||||||||||||||||||||||||
set serveroutput on |
||||||||||||||||||||||||||||
| IS_DB_PDB_SEED | ||||||||||||||||||||||||||||
| Returns TRUE if in PDB$SEED and FALSE if in any other container | dbms_registry.is_db_pdb_seed RETURN BOOLEAN; |
|||||||||||||||||||||||||||
set serveroutput on |
||||||||||||||||||||||||||||
| IS_DB_ROOT | ||||||||||||||||||||||||||||
| Returns TRUE if in CDB$ROOT and FALSE if in any other container | dbms_registry.is_db_root RETURN BOOLEAN; |
|||||||||||||||||||||||||||
set serveroutput on |
||||||||||||||||||||||||||||
| IS_IN_REGISTRY | ||||||||||||||||||||||||||||
| Determines whether a component is loaded into the registry | dbms_registry.is_in_registry(comp_id IN VARCHAR2) RETURN BOOLEAN; |
|||||||||||||||||||||||||||
set serveroutput on |
||||||||||||||||||||||||||||
| IS_IN_UPGRADE_MODE | ||||||||||||||||||||||||||||
| Definitely returns FALSE if not in upgrade mode. Have not tested to determine if it returns TRUE or nothing when actually in upgrade mode | dbms_registry.is_in_upgrade_mode RETURN BOOLEAN; |
|||||||||||||||||||||||||||
conn / as sysdba |
||||||||||||||||||||||||||||
| IS_LOADED | ||||||||||||||||||||||||||||
| Returns 1 if the componenet version number matches the name-value pair submitted: Otherwise 0 | dbms_registry.is_loaded( |
|||||||||||||||||||||||||||
SELECT comp_id, version |
||||||||||||||||||||||||||||
| IS_SERVER_COMPONENT | ||||||||||||||||||||||||||||
| Returns 1 if the component name is a server component, else 0 | dbms_registry.is_server_component(comp_id VARCHAR2) RETURN NUMBER DETERMINISTIC; |
|||||||||||||||||||||||||||
SELECT dbms_registry.is_server_component('RAC'); |
||||||||||||||||||||||||||||
| IS_STARTUP_REQUIRED | ||||||||||||||||||||||||||||
| Returns whether a registry component requires a startup | dbms_registry.is_startup_required(comp_id IN VARCHAR2) RETURN NUMBER; |
|||||||||||||||||||||||||||
SELECT comp_id, procedure, startup |
||||||||||||||||||||||||||||
| IS_STATS_FROM_UPGRADE | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.is_stats_from_upgrade RETURN BOOLEAN; |
|||||||||||||||||||||||||||
BEGIN |
||||||||||||||||||||||||||||
| IS_TRACE_EVENT_SET | ||||||||||||||||||||||||||||
| Undocumented but the behavior is not expected. This has been reported to BugDB. | dbms_registry.is_trace_event_set(trace_event VARCHAR2) RETURN BOOLEAN; |
|||||||||||||||||||||||||||
BEGIN |
||||||||||||||||||||||||||||
| IS_UPGRADE_RUNNING | ||||||||||||||||||||||||||||
| Returns TRUE if an upgrade is in progress | dbms_registry.is_upgrade_running RETURN BOOLEAN; |
|||||||||||||||||||||||||||
BEGIN |
||||||||||||||||||||||||||||
| IS_VALID | ||||||||||||||||||||||||||||
| Determines if a registry component is valid | dbms_registry.is_valid( |
|||||||||||||||||||||||||||
BEGIN |
||||||||||||||||||||||||||||
| LOADED | ||||||||||||||||||||||||||||
| Indicate load complete | dbms_registry.loaded( |
|||||||||||||||||||||||||||
exec dbms_registry.loaded('CATALOG'); |
||||||||||||||||||||||||||||
| LOADING | ||||||||||||||||||||||||||||
| Indicate that the component is in the process of being loaded Overload 1 |
dbms_registry.loading( |
|||||||||||||||||||||||||||
set linesize 121 |
||||||||||||||||||||||||||||
| Overload 2 | dbms_registry.loading( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| NOTHING_SCRIPT | ||||||||||||||||||||||||||||
| Returns the path to nothing.sql | dbms_registry.nothing_script RETURN VARCHAR2; |
|||||||||||||||||||||||||||
SELECT dbms_registry.nothing_script; |
||||||||||||||||||||||||||||
| NUM_OF_EXADATA_CELLS | ||||||||||||||||||||||||||||
| Returns the number of Exadata cells | dbms_registry.num_of_exadata_cells RETURN NUMBER; |
|||||||||||||||||||||||||||
SELECT dbms_registry.num_of_exadata_cells; |
||||||||||||||||||||||||||||
| OPTION_OFF | ||||||||||||||||||||||||||||
| Disables a component option in the registry. Warning: We are not aware of any method of re-enabling an option so don't do this except in a throw-away training database. |
dbms_registry.option_off(comp_id IN VARCHAR2); |
|||||||||||||||||||||||||||
SELECT comp_id, comp_name, status, startup |
||||||||||||||||||||||||||||
| PREV_VERSION | ||||||||||||||||||||||||||||
| Returns the previous version of a registry component | dbms_registry.prev_version(comp_id IN VARCHAR2) RETURN VARCHAR2; |
|||||||||||||||||||||||||||
SELECT dbms_registry.prev_version('XML'); |
||||||||||||||||||||||||||||
| PREV_VERSION_FULL | ||||||||||||||||||||||||||||
| Returns the previous full version number string | dbms_registry.prev_version_full(comp_id IN VARCHAR2) RETURN VARCHAR2; |
|||||||||||||||||||||||||||
SELECT dbms_registry.prev_version_full('RAC'); |
||||||||||||||||||||||||||||
| REMOVED | ||||||||||||||||||||||||||||
| A component has been removed from the registry | dbms_registry.removed(comp_id IN VARCHAR2); |
|||||||||||||||||||||||||||
exec dbms_registry.removed('EXF'); |
||||||||||||||||||||||||||||
| REMOVING | ||||||||||||||||||||||||||||
| Removes a component from the registry | dbms_registry.removing(comp_id IN VARCHAR2); |
|||||||||||||||||||||||||||
-- drop the Expression Filter user with cascade option |
||||||||||||||||||||||||||||
| RESET_VERSION | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.reset_version(comp_id IN VARCHAR2); |
|||||||||||||||||||||||||||
exec dbms_registry.reset_version('APS'); |
||||||||||||||||||||||||||||
| RU_APPLY | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.ru_apply( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| RU_ROLLBACK | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.ru_rollback( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| SCHEMA | ||||||||||||||||||||||||||||
| Returns the schema owner of a registry component | dbms_registry.schema(comp_id IN VARCHAR2) RETURN VARCHAR2; |
|||||||||||||||||||||||||||
SELECT dbms_registry.schema('EXF'); |
||||||||||||||||||||||||||||
| SCHEMA_LIST | ||||||||||||||||||||||||||||
| Returns the schema owners of a registry component | dbms_registry.schema_list(comp_id IN VARCHAR2) RETURN dbms_registry.schema_list_t; |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| SCHEMA_LIST_STRING | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.schema_list_string(comp_id IN VARCHAR2) RETURN VARCHAR2; |
|||||||||||||||||||||||||||
SELECT dbms_registry.schema_list_string('EXF'); |
||||||||||||||||||||||||||||
| SCRIPT | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.script( |
|||||||||||||||||||||||||||
-- create helper package for text index on xdb resource data |
||||||||||||||||||||||||||||
| SCRIPT_PATH | ||||||||||||||||||||||||||||
| Returns the path to the script for a registry component | dbms_registry.script_path(comp_id IN VARCHAR2) RETURN VARCHAR2; |
|||||||||||||||||||||||||||
SELECT dbms_registry.script_path('EXF'); |
||||||||||||||||||||||||||||
| SCRIPT_PREFIX | ||||||||||||||||||||||||||||
| Returns a registry component's prefix | dbms_registry.script_prefix(comp_id IN VARCHAR2) RETURN VARCHAR2; |
|||||||||||||||||||||||||||
SELECT dbms_registry.script_prefix('EXF'); |
||||||||||||||||||||||||||||
| SESSION_NAMESPACE | ||||||||||||||||||||||||||||
| Returns the namespace for a session | dbms_registry.session_namespace RETURN VARCHAR2; |
|||||||||||||||||||||||||||
SELECT dbms_registry.session_namespace; |
||||||||||||||||||||||||||||
| SET_COMP_NAMESPACE | ||||||||||||||||||||||||||||
| Sets a registry component's namespace | dbms_registry.set_comp_namespace( |
|||||||||||||||||||||||||||
exec dbms_registry.set_comp_namespace('RAC', 'SERVER'); |
||||||||||||||||||||||||||||
| SET_EDITION | ||||||||||||||||||||||||||||
| Sets Database Edition: EE or SE Overload 1 |
dbms_registry.set_edition(comp_id IN VARCHAR2); |
|||||||||||||||||||||||||||
exec dbms_registry.set_edition('ORDIM'); |
||||||||||||||||||||||||||||
| Overload 2 | dbms_registry.set_edition( |
|||||||||||||||||||||||||||
exec dbms_registry.set_edition('ORDIM', 'EE'); |
||||||||||||||||||||||||||||
| SET_PROGRESS_ACTION | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.set_progress_action( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| SET_PROGRESS_STEP | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.set_progress_step( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| SET_PROGRESS_VALUE | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.set_progress_value( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| SET_RDBMS_STATUS | ||||||||||||||||||||||||||||
| Sets the component status in the registry 1 = VALID |
dbms_registry.set_rdbms_status( |
|||||||||||||||||||||||||||
SELECT status |
||||||||||||||||||||||||||||
| SET_REQUIRED_COMPS | ||||||||||||||||||||||||||||
| Undocumented Overload 1 |
dbms_registry.set_required_comps( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| Overload 2 | dbms_registry.set_required_comps( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| SET_SESSION_NAMESPACE | ||||||||||||||||||||||||||||
| Sets the registry namespace for a component | dbms_registry.set_session_namespace(namespace IN VARCHAR2); |
|||||||||||||||||||||||||||
exec dbms_registry.set_session_namespace('SERVER'); |
||||||||||||||||||||||||||||
| STARTUP_COMPLETE | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.startup_complete(comp_id IN VARCHAR2); |
|||||||||||||||||||||||||||
exec dbms_registry.startup_complete('RAC'); |
||||||||||||||||||||||||||||
| STARTUP_REQUIRED | ||||||||||||||||||||||||||||
| Updates the registry to indicate that a component requires startup | dbms_registry.startup_required(comp_id IN VARCHAR2); |
|||||||||||||||||||||||||||
exec dbms_registry.startup_required('OLS'); |
||||||||||||||||||||||||||||
| STATUS | ||||||||||||||||||||||||||||
| Determine the status of a database component from the registry | dbms_registry.status(comp_id IN VARCHAR2) RETURN VARCHAR2; |
|||||||||||||||||||||||||||
BEGIN |
||||||||||||||||||||||||||||
| STATUS_NAME | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.status_name(status IN NUMBER) RETURN VARCHAR2; |
|||||||||||||||||||||||||||
SELECT dbms_registry.status_name(1); |
||||||||||||||||||||||||||||
| SUBCOMPONENTS | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.subcomponents( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| UPDATE_SCHEMA_LIST | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.update_schema_list( |
|||||||||||||||||||||||||||
set serveroutput on |
||||||||||||||||||||||||||||
| UPGRADED | ||||||||||||||||||||||||||||
| Undocumented The demo, at right, is copied from ?/rdbms/admin/exfcpu.sql |
dbms_registry.upgraded( |
|||||||||||||||||||||||||||
ALTER SESSION SET CURRENT_SCHEMA = EXFSYS; |
||||||||||||||||||||||||||||
| UPGRADING | ||||||||||||||||||||||||||||
| Undocumented Overload 1 |
dbms_registry.upgrading( |
|||||||||||||||||||||||||||
See Upgraded Demo Above |
||||||||||||||||||||||||||||
| Overload 2 | dbms_registry.upgrading( |
|||||||||||||||||||||||||||
See Upgraded Demo Above |
||||||||||||||||||||||||||||
| VALID | ||||||||||||||||||||||||||||
| Mark an item in the registry as valid | dbms_registry.valid(comp_id IN VARCHAR2); |
|||||||||||||||||||||||||||
See INVALID Demo Above |
||||||||||||||||||||||||||||
| VERSION | ||||||||||||||||||||||||||||
| Returns the version of a registry component | dbms_registry.version(comp_id IN VARCHAR2)
RETURN VARCHAR2; |
|||||||||||||||||||||||||||
SELECT dbms_registry.version('CATPROC'); |
||||||||||||||||||||||||||||
| VERSION_FULL | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.version_full(comp_id IN VARCHAR2) RETURN VARCHAR2; |
|||||||||||||||||||||||||||
SELECT dbms_registry.version_full('XML'); |
||||||||||||||||||||||||||||
| VERSION_GREATER | ||||||||||||||||||||||||||||
| Undocumented | dbms_registry.version_greater( |
|||||||||||||||||||||||||||
| TBD | ||||||||||||||||||||||||||||
| This site is maintained by Daniel Morgan. Last Updated: | This site is protected by copyright and trademark laws under U.S. and International law. © 1998-2026 Daniel A. Morgan All Rights Reserved | ||||||||
|
|
|||||||||