• Oracle Create,Delete,Alter



    ----------------------Create Table--------------------------------
    create table SMS_EXTERNALSYSSMSREQUEST
    (
      SMSSENDRECID   VARCHAR2(20) primary key not null,
      SOURCEREF      NUMBER(38) not null,
      SURVEYSVCNO    VARCHAR2(30) not null,
      SURVEYNAME     VARCHAR2(30),
      SENDDATETIME   DATE,
      CREATEUSERID   VARCHAR2(10) not null,
      CREATEDATETIME DATE not null,
      CHANGEUSERID   VARCHAR2(10),
      CHANGEDATETIME DATE,
      CUSTID         VARCHAR2(144),
      ACCTID         VARCHAR2(144),
      SVCNO          VARCHAR2(144),
      SOURCEID       VARCHAR2(50),
      ADDITIONALINFO VARCHAR2(1000)
    )
    ------------------------Alter Table-------------------------------------
    Alter table SMS_GREYLIST
    add(
        REQREFID NUMBER(38),
        SOURCECODE NUMBER(38) DEFAULT 0
    )

    Alter table SMS_GREYLIST
    modify(
        REQREFID NUMBER(38),
        SOURCECODE NUMBER(38) DEFAULT 0
    )

    Alter table SMS_GREYLIST
    drop(
        REQREFID,
        SOURCECODE
    )
    ------------------------Drop Table------------------------------------------
    Drop Table SMS_EXTERNALSYSSMSREQUEST

    ------------------------Define Sequence----------------------------------------

    create Sequence SEQ_UNSUBREQ
    increment by 1 --add count every time
    start with 1
    nomaxvalue
    nocycle
    cache 10;

    -----------------------Add comments to the columns--------------------------
    comment on column sms_aicrequest.REASON1   is 'Survey Type'

    -----------------------Add comments to the columns--------------------------
    comment on table TABLENAME  is '表的注释'

  • 相关阅读:
    多路复用
    Nginx配置优化
    flask blinker信号
    Go基础
    Flask简单部署至kubernetes
    Flask源码阅读
    Python性能分析工具
    js sort()方法改变原数组了怎么办
    js事件机制
    ubuntu的zip、gzip、bzip2命令学习
  • 原文地址:https://www.cnblogs.com/ganting/p/5077105.html
Copyright © 2020-2023  润新知