Oracle XML_SCHEMA_NAME_PRESENT
Version 12.2.0.1

General Information
Library Note Morgan's Library Page Header
The Library is currently in the process of being upgraded from Oracle Database Version 12.1.0.2 to 12.2.0.1. Demos are being upgraded to reflect the new Container paradigm as well as EBR (Edition Based Redefinition) and may contain references to CDBs, PDBs, and other objects you may not be familiar with such as CDB_OBJECTS_AE: Welcome to 12c.

Do you remember when mainframes were replaced by client-server? When client-server was replaced by n-tier architecture? The "Cloud" is a distraction ... DevOps is not. Prepare for the future.
Purpose Undocumented
AUTHID DEFINER
Dependencies
ALL_ANNOTATION_TEXT_METADATA ALL_STREAMS_UNSUPPORTED KU$_REFPARTTABPROP_VIEW
ALL_OBJECTS DV$OUT KU$_STRMTABLE_VIEW
ALL_OBJECTS_AE KU$_10_1_HTABLE_VIEW KU$_TABPROP_VIEW
ALL_PROBE_OBJECTS KU$_HTABLE_VIEW KU$_VIEWPROP_VIEW
ALL_SDO_CSW_SERVICE_INFO KU$_M_VIEW_H_VIEW KU$_VIEW_EXISTS_VIEW
ALL_SDO_INDEX_HISTOGRAM KU$_M_VIEW_LOG_H_VIEW KU$_ZM_VIEW_H_VIEW
ALL_STREAMS_COLUMNS KU$_M_ZONEMAP_H_VIEW USER_SDO_CSW_SERVICE_INFO
ALL_STREAMS_NEWLY_SUPPORTED KU$_PFHTABPROP_VIEW USER_SDO_INDEX_HISTOGRAM
Documented No
First Available 10.1
Security Model Owned by SYS with no privileges granted
Source {ORACLE_HOME}/rdbms/admin/prvtxschnp.plb
 
IS_SCHEMA_PRESENT
Undocumented - but here's the source code. Some of the slickest coding I've ever seen. <g>

This code is based on sample code found in catxdbdv.sql in the 12c Beta
FUNCTION is_schema_present(objname IN VARCHAR2, userno IN NUMBER) RETURN NUMBER AS
BEGIN
  RETURN 0;
END;
SELECT xml_schema_name_present.is_schema_present('Larry Ellison', 1)
FROM dual;
This demo code was extracted from cdcore.sql and reformatted for clarity AND 1 = (
  SELECT /*+ NO_MERGE */ xml_schema_name_present.is_schema_present(o.name, u2.id2) id1
  FROM (
    SELECT /*+ NO_MERGE */ userenv('SCHEMAID') id2
    FROM dual) u2));

Related Topics
Built-in Functions
Built-in Packages
What's New In 12cR1
What's New In 12cR2

Morgan's Library Page Footer
This site is maintained by Dan Morgan. Last Updated: This site is protected by copyright and trademark laws under U.S. and International law. © 1998-2017 Daniel A. Morgan All Rights Reserved