Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Where can I get the catalog information in target Database

Re: Where can I get the catalog information in target Database

From: DA Morgan <damorgan_at_psoug.org>
Date: Wed, 18 Jul 2007 05:57:08 -0700
Message-ID: <1184763428.896211@bubbleator.drizzle.com>


manjsuha wrote:
> Hi All,
>
> Prob: Where can I get the name of the catalog DB from the target DB?
> I can get the list of registered target databaes information easily
> from the catalog database views. But the I am unable to get the
> reverse?
>
> Version: 10g R2
>
> Thanks
> Manjusha

The first thing you need to do is learn that Oracle is NOT SQL Server: There is no such thing as a catalog database because the word database has a completely different meaning in Oracle from SQL Server.

Go to amazon.com and purchase copies of each of Tom Kyte's books and read the sections pertaining to Oracle for those coming from other RDBMS products. Also go to http://tahiti.oracle.com and read the concept docs because right now you are more likely to do damage than good.

That said the SCHEMA that owns the catalog is SYS. The catalog is present as permanent tables (designed to be read by Oracle and views designed to be read by humans). Perform the following queries:

SELECT table_name
FROM dba_tables
WHERE table_name LIKE '%$%'
ORDER BY 1; SELECT view_name
FROM all_views
WHERE view_name LIKE 'DBA%';

SELECT view_name
FROM all_views
WHERE view_name LIKE 'ALL%';

SELECT view_name
FROM all_views
WHERE view_name LIKE 'USER%';

If you don't already know the difference between dba_tables, all_tables, and user_tables definitely hit the docs before doing anything else.

-- 
Daniel A. Morgan
University of Washington
damorgan_at_x.washington.edu (replace x with u to respond)
Puget Sound Oracle Users Group
www.psoug.org
Received on Wed Jul 18 2007 - 07:57:08 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US