WEB开发网
开发学院数据库Oracle Oracle中如何从BasicFile迁移到SecureFile 阅读

Oracle中如何从BasicFile迁移到SecureFile

 2009-04-17 13:13:04 来源:WEB开发网   
核心提示: --- 创建表TRBTKT.SECURE_TICKETS的一个改良版本,使用分区划分SecureFile LOB的存储,Oracle中如何从BasicFile迁移到SecureFile(2),基于STATUS 的值设置合适的保留周期DROPTABLEtrbtkt.secure_ticket

--- 创建表TRBTKT.SECURE_TICKETS的一个改良版本,使用分区划分SecureFile LOB的存储,基于STATUS 的值设置合适的保留周期

DROP TABLE trbtkt.secure_tickets PURGE;
CREATE TABLE trbtkt.secure_tickets (
tkt_idNUMBER
,description  VARCHAR2(30)
,submit_dtm   TIMESTAMP
,statusVARCHAR2(8)
,document    BLOB
,scrnimg    BLOB
)
LOB(document)  
STORE AS SECUREFILE (
TABLESPACE securefiles
DISABLE STORAGE IN ROW
CACHE
)
,LOB(scrnimg)  
STORE AS SECUREFILE (
TABLESPACE securefiles
DISABLE STORAGE IN ROW
CACHE READS
)
PARTITION BY LIST (status) (
PARTITION sts_open 
VALUES ('OPEN')
LOB (document) STORE AS SECUREFILE (KEEP_DUPLICATES NOCOMPRESS)
,LOB (scrnimg) STORE AS SECUREFILE (KEEP_DUPLICATES COMPRESS)
,PARTITION sts_pending
VALUES ('PENDING')
LOB (document) STORE AS SECUREFILE (KEEP_DUPLICATES NOCOMPRESS)
,LOB (scrnimg) STORE AS SECUREFILE (DEDUPLICATE COMPRESS)
,PARTITION sts_closed
VALUES ('CLOSED')
LOB (document) STORE AS SECUREFILE (DEDUPLICATE COMPRESS)
,LOB (scrnimg) STORE AS SECUREFILE (DEDUPLICATE COMPRESS HIGH)
,PARTITION sts_other
VALUES (DEFAULT)
LOB (document) STORE AS SECUREFILE (DEDUPLICATE COMPRESS HIGH)
,LOB (scrnimg) STORE AS SECUREFILE (DEDUPLICATE COMPRESS HIGH)
)
;
 

--注释
COMMENT ON TABLE trbtkt.secure_tickets
IS 'Contains Trouble Ticket transaction data';
COMMENT ON COLUMN trbtkt.secure_tickets.tkt_id
IS 'Unique identifier for a Trouble Ticket';
COMMENT ON COLUMN trbtkt.secure_tickets.description
IS 'Trouble Ticket Description';
COMMENT ON COLUMN trbtkt.secure_tickets.submit_dtm
IS 'Trouble Ticket Submission Time Stamp';
COMMENT ON COLUMN trbtkt.secure_tickets.status
IS 'Trouble Ticket Status';
COMMENT ON COLUMN trbtkt.secure_tickets.document
IS 'Large Object (LOB) that contains a Microsoft Word document that provides detailed information about a Trouble Ticket';
COMMENT ON COLUMN trbtkt.secure_tickets.scrnimg
IS 'Large Object (LOB) that contains a screen print or other image that helps a problem solver identify how to act on a Trouble Ticket';

上一页  1 2 3 4 5 6 7  下一页

Tags:Oracle 如何 BasicFile

编辑录入:爽爽 [复制链接] [打 印]
赞助商链接