A
A
AlexCheck2016-07-13 00:34:34
Oracle
AlexCheck, 2016-07-13 00:34:34

Is it possible to get Oracle database schema using sql query?

Good night everybody.

I ask you to tell the Oracle experts whether it is possible to obtain a database schema with commands for creating tables by means of a sql query to the Oracle database.
For example, using sqldeveloper or sqlplus.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
V
Vapaamies, 2016-07-13
@vapaamies

Oracle has a DBMS_METADATA package that allows you to pull out information about tables in the form that the exp or datapump utility saves them.
You can also use the built-in features of any advanced Oracle administration/development program: TOAD, PL/SQL Developer, etc.

A
Anton, 2016-07-22
@Oraclist

Well, the last option is to export/import schemas with ROWS=0 (no data). Not exactly SQL, but might come in handy.

S
shushpanio, 2016-07-13
@shushpanio

SELECT *
FROM all_tab_columns
or so
select * from v$database - info about the database to which it is connected
select * from v$instance - info about the oracle instance
select * from dba_objects where object_type='TABLE' - info about tables

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question