> Ex..."/>
您好,登錄后才能下訂單哦!
導讀 | 如何用PLSQL導出表結構,不用登陸數(shù)據(jù)庫存,直接用plsql工具怎么導出指定表的表結構呢?下面我就介紹下如何導出。 |
-->> Exports User Ojbects
-->> 選中需要導出的table,squence,view,type,function,procedure,trigger。
-->> 選擇User
-->>勾選Include storege或者去掉勾選(include storege表示表空間的意思
-->>選擇導出文件存放目錄
-->>Export按鈕導出
1)不勾選導出的sql如下:
create table TRAVELSKY_XREZAGENT.AUDIT_TRAIL ( product VARCHAR2(32 CHAR) not null, environment VARCHAR2(32 CHAR) not null, server VARCHAR2(32 CHAR) not null, resource_path VARCHAR2(256 CHAR) not null, action VARCHAR2(4 CHAR) not null, username VARCHAR2(32 CHAR) not null, usergroup VARCHAR2(32 CHAR) not null, address VARCHAR2(32 CHAR) not null, timestamp DATE default TO_DATE('00-01-01 00:00:00','YY-MM-DD HH24:MI:SS') not null, status VARCHAR2(16 CHAR), data NCLOB ) ;
2)勾選后導出的sql如下,加上了table所屬的表空間,以及可用的表空間限制
create table TRAVELSKY_XREZAGENT.AUDIT_TRAIL ( product VARCHAR2(32 CHAR) not null, environment VARCHAR2(32 CHAR) not null, server VARCHAR2(32 CHAR) not null, resource_path VARCHAR2(256 CHAR) not null, action VARCHAR2(4 CHAR) not null, username VARCHAR2(32 CHAR) not null, usergroup VARCHAR2(32 CHAR) not null, address VARCHAR2(32 CHAR) not null, timestamp DATE default TO_DATE('00-01-01 00:00:00','YY-MM-DD HH24:MI:SS') not null, status VARCHAR2(16 CHAR), data NCLOB ) tablespace OPENJAW_DATA pctfree 10 initrans 1 maxtrans 255;
1)不勾選Include User
create table AUDIT_TRAIL ( product VARCHAR2(32 CHAR) not null, environment VARCHAR2(32 CHAR) not null, server VARCHAR2(32 CHAR) not null, resource_path VARCHAR2(256 CHAR) not null, action VARCHAR2(4 CHAR) not null, username VARCHAR2(32 CHAR) not null, usergroup VARCHAR2(32 CHAR) not null, address VARCHAR2(32 CHAR) not null, timestamp DATE default TO_DATE('00-01-01 00:00:00','YY-MM-DD HH24:MI:SS') not null, status VARCHAR2(16 CHAR), data NCLOB ) ;
2)勾選上Include User,會在create table tablename的tablename前面加上User的名字,如下多了一個TRAVELSKY_XREZAGENT
create table TRAVELSKY_XREZAGENT.AUDIT_TRAIL ( product VARCHAR2(32 CHAR) not null, environment VARCHAR2(32 CHAR) not null, server VARCHAR2(32 CHAR) not null, resource_path VARCHAR2(256 CHAR) not null, action VARCHAR2(4 CHAR) not null, username VARCHAR2(32 CHAR) not null, usergroup VARCHAR2(32 CHAR) not null, address VARCHAR2(32 CHAR) not null, timestamp DATE default TO_DATE('00-01-01 00:00:00','YY-MM-DD HH24:MI:SS') not null, status VARCHAR2(16 CHAR), data NCLOB ) ;
原文來自: https://www.linuxprobe.com/plsql-dc-bijg.html
免責聲明:本站發(fā)布的內容(圖片、視頻和文字)以原創(chuàng)、轉載和分享為主,文章觀點不代表本網(wǎng)站立場,如果涉及侵權請聯(lián)系站長郵箱:is@yisu.com進行舉報,并提供相關證據(jù),一經(jīng)查實,將立刻刪除涉嫌侵權內容。