PL/SQL也是一种程序语言,叫做过程化SQL语言(Procedural Language/SQL)。Oracle PL/SQL语言是结合了结构化查询与Oracle自身过程控制为一体的强大语言,PL/SQL不但支持更多的数据类型,拥有自身的变量声明、赋值语句,而且还有条件、循环等流程控制语句。过程控制结构与SQL数据处理能力无缝的结合形成了强大的编程语言,可以创建过程和函数以及程序包。
1:进行plsql后选怎Tools
–>> Exports User Ojbects
–>> 选中需要导出的table,squence,view,type,function,procedure,trigger。
–>> 选择User
–>>勾选Include storege或者去掉勾选(include storege表示表空间的意思
–>>选择导出文件存放目录
–>>Export按钮导出
2:下面具体解释一下Include Storage勾选和不勾选的区别
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;
3:下面解释一下Include User勾选和不勾选的区别。
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
)
;
以上就是良许教程网为各位朋友分享的Linu系统相关内容。想要了解更多Linux相关知识记得关注公众号“良许Linux”,或扫描下方二维码进行关注,更多干货等着你 !