0

In Oracle Database, there are two XML-related data types, SYS.XMLTYPE and PUBLIC.XMLTYPE. What is the difference between them?

2

That's simple.

Check the object type of the "public" object

select object_type
from all_objects
where owner = 'PUBLIC'
and object_name = 'XMLTYPE';

the above returns

OBJECT_TYPE
-----------
SYNONYM    

So we have to look into all_synonyms:

select owner, synonym_name, table_owner, table_name
from all_synonyms
where synonym_name = 'XMLTYPE';

returns:

OWNER  | SYNONYM_NAME | TABLE_OWNER | TABLE_NAME
-------+--------------+-------------+-----------
PUBLIC | XMLTYPE      | SYS         | XMLTYPE   
  • @PRADEEPAGILERAJEGOWDA: please accept the answer then so that your question is marked as resolved – a_horse_with_no_name Nov 17 '17 at 13:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.