标签:
很多人使用PD的时候就问有没有制作自动升级脚本的功能。其实是有的。/*==============================================================*/
/* Database name: Database */
/* DBMS name: ORACLE Version 9i */
/* Created on: 2007-9-6 11:12:26 */
/*==============================================================*/ alter table SY_MsgReceiver drop constraint FK_SY_MSGRE_SY_MSGREC_SY_MSGSE / drop table tmp_SY_MsgSend cascade constraints / /*==============================================================*/
/* Table: tmp_SY_MsgSend */
/*==============================================================*/ create table tmp_SY_MsgSend (
MS_ID NUMBER(10) not null,
MS_Content VARCHAR2(4000),
MS_SendTime DATE,
MS_Type VARCHAR2(4),
MS_Sender NUMBER(8),
MS_Status NUMBER(1) default 1 not null,
MS_MsgSource NUMBER(2) default 1 not null,
Column_8 CHAR(10) ) / insert into tmp_SY_MsgSend (MS_ID, MS_Content, MS_SendTime, MS_Type, MS_Sender, MS_Status, MS_MsgSource)
select MS_ID, MS_Content, MS_SendTime, MS_Type, MS_Sender, MS_Status, MS_MsgSource from SY_MsgSend / drop table SY_MsgSend cascade constraints / /*==============================================================*/
/* Table: SY_MsgSend */
/*==============================================================*/ create table SY_MsgSend (
MS_ID NUMBER(10) not null,
MS_Content VARCHAR2(4000),
MS_SendTime DATE,
MS_Type VARCHAR2(4),
MS_Sender NUMBER(8),
MS_Status NUMBER(1) default 1 not null,
MS_MsgSource NUMBER(2) default 1 not null,
constraint PK_SY_MSGSEND primary key (MS_ID) ) tablespace TBS_EOFFICE / insert into SY_MsgSend (MS_ID, MS_Content, MS_SendTime, MS_Type, MS_Sender, MS_Status, MS_MsgSource)
select MS_ID, MS_Content, MS_SendTime, MS_Type, MS_Sender, MS_Status, MS_MsgSource from tmp_SY_MsgSend / /*==============================================================*/
/* Index: Index_47 */
/*==============================================================*/
create index Index_47 on SY_MsgSend ( MS_Sender ASC ) tablespace TBS_IDX_Eoffice / alter table SY_MsgReceiver add constraint FK_SY_MSGRE_SY_MSGREC_SY_MSGSE foreign key (MS_ID)
references SY_MsgSend (MS_ID) on delete cascade /
标签:
原文地址:http://www.cnblogs.com/springwind268/p/4246316.html