CREATE TABLE SQL_COMMAND
(
SQL_COMMAND_ID NUMBER(10) NOT NULL,
API_CODE VARCHAR2(50 BYTE) NOT NULL,
API_NAME VARCHAR2(500 BYTE) NOT NULL,
RETURN_TYPE VARCHAR2(2 BYTE),
COMMAND_TYPE VARCHAR2(2 BYTE),
DBLINK_ VARCHAR2(500 BYTE),
GROUP_TYPE VARCHAR2(1 BYTE),
APP_TYPE VARCHAR2(1 BYTE)
)
TABLESPACE DATA
RESULT_CACHE (MODE DEFAULT)
PCTUSED 0
PCTFREE 10
INITRANS 1
MAXTRANS 255
STORAGE (
INITIAL 64K
NEXT 1M
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
BUFFER_POOL DEFAULT
FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT
)
NOLOGGING
NOCOMPRESS
NOCACHE
NOPARALLEL
MONITORING;
-- Them du lieu
CREATE TABLE SQL_COMMAND_CLOB
(
SQL_COMMAND_ID NUMBER(10) NOT NULL,
API_CODE VARCHAR2(50 BYTE) NOT NULL,
API_NAME VARCHAR2(500 BYTE) NOT NULL,
SQL_COMMAND CLOB,
RETURN_TYPE VARCHAR2(2 BYTE),
COMMAND_TYPE VARCHAR2(2 BYTE),
DBLINK_ VARCHAR2(500 BYTE),
GROUP_TYPE VARCHAR2(1 BYTE),
APP_TYPE VARCHAR2(1 BYTE)
)
TABLESPACE DATA
RESULT_CACHE (MODE DEFAULT)
PCTUSED 0
PCTFREE 10
INITRANS 1
MAXTRANS 255
STORAGE (
INITIAL 64K
NEXT 1M
MINEXTENTS 1
MAXEXTENTS UNLIMITED
PCTINCREASE 0
BUFFER_POOL DEFAULT
FLASH_CACHE DEFAULT
CELL_FLASH_CACHE DEFAULT
)
NOLOGGING
NOCOMPRESS
NOCACHE
NOPARALLEL
MONITORING;
insert into binhtv.sql_command_clob
SELECT SQL_COMMAND_ID,
API_CODE,
API_NAME ,
to_lob(SQL_COMMAND),
RETURN_TYPE,
COMMAND_TYPE,
DBLINK_,
GROUP_TYPE,
APP_TYPE from sql_command where rownum<10;
commit;