Home > database >  How to built inside the oracle table into a SQL statement
How to built inside the oracle table into a SQL statement

Time:09-21

Excuse me, how do you get the oracle database built inside the table into a SQL statement to export to

CodePudding user response:

Using tools PLSQL dev, can check to your table statements,

CodePudding user response:

1. Pl, is used to derive the user object
2. Used in exp up sqlplus statements export

CodePudding user response:

Baidu this, dbms_meate. Get_ddl ()

CodePudding user response:

 
The select dbms_metadata. Get_ddl (' TABLE ', 'EMP) from dual

CodePudding user response:

1. PLSQL, is used to derive the user object
2. Used in exp up sqlplus statements export

CodePudding user response:

With PLSQL selected table name right view - view the SQL, you can view the replication table statements, export user object in the tool can export table structure,

CodePudding user response:

Pl/SQL tools & gt; Export table can choose table is deduced, and have built table statements and data, don't want to have data can be filtered out

CodePudding user response:

Pl/SQL tools & gt; Export table can choose table is deduced, and have built table statements and data, don't want to have data can be filtered out

CodePudding user response:

Plsqldev tool can view the SQL statements, if multiple tables derived using dbms_meate get_ddl () to the export

CodePudding user response:

DBMS_METADATA. GET_DDL ()

CodePudding user response:

With a TOAD also can see the SQL statement,

CodePudding user response:

 
In PL/SQL; Check the table SQL statement, and then determine whether to export, general PL/SQL is used to derive the data can be, this is simple;
You can also use EXPDP export, the following syntax:
Create the directory dump_dir as' D: \ dump '; - create a DIRECTORY object (needs to create a folder)
Grant read, write on directory dump_dir to Scott; - grants the user permission to use a directory
Export the table again, here are exported under the Scott user of emp and dept table,
Expdp Scott/Scott directory=dump_dir dumpfile=TAB. The DMP tables=emp, dept

CodePudding user response:

DBMS_METADATA. GET_DDL ()
  • Related