zoukankan      html  css  js  c++  java
  • oracle创建临时表

    -- oracle临时表,先创建,后使用
    create global temporary table TMP_CUSTOMERINFO
    (
      BRANCHFLAG      CHAR(3) not null,
      CUSTOMERID      VARCHAR2(11) not null,
      CUSTOMERNO      VARCHAR2(20),
      CUSTOMERNAME    VARCHAR2(200),
      GROUPCUSTOMERNO VARCHAR2(20),
      CUSTOMERTYPE    CHAR(1),
      DENGJI          CHAR(3)
    )
    on commit delete rows          --在事务提交后数据就已经清除了.
    --or
    --on commit preserve rows;   --在会话中止时或者导常退出时数据都会被清除掉.

    -- Add comments to the columns
    comment on column TMP_CUSTOMERINFO.BRANCHFLAG
      is '公司标识';
    comment on column TMP_CUSTOMERINFO.CUSTOMERID
      is '客户id';
    comment on column TMP_CUSTOMERINFO.CUSTOMERNO
      is '客户编号';
    comment on column TMP_CUSTOMERINFO.CUSTOMERNAME
      is '客户名称';
    comment on column TMP_CUSTOMERINFO.GROUPCUSTOMERNO
      is '客户统一编号';
    comment on column TMP_CUSTOMERINFO.CUSTOMERTYPE
      is '客户类别';
    comment on column TMP_CUSTOMERINFO.DENGJI
      is '客户等级';
    -- Create/Recreate primary, unique and foreign key constraints
    alter table TMP_CUSTOMERINFO
      add primary key (BRANCHFLAG, CUSTOMERID);

  • 相关阅读:
    Mybatis在oracle批量更新
    WebService小记
    java基本排序
    ant使用
    python 集合
    amazon-aws 使用 SNS 发送短信
    Html5+ 开发APP 后台运行代码
    CentOS7 -防火墙
    java 模拟表单方式提交上传文件
    修改pom项目版本 jenkins 关联 shell命令
  • 原文地址:https://www.cnblogs.com/pan11jing/p/1513110.html
Copyright © 2011-2022 走看看