zoukankan      html  css  js  c++  java
  • SQLServer 中的存储过程中判断临时表是否存在,存在则删除临时表

    IF OBJECT_ID('TEMPDB..#BCROSSREFERENCE ') IS NOT NULL
    DROP TABLE #BCROSSREFERENCE 
    IF OBJECT_ID('TEMPDB..#SCVTMP_BCUSTOMER') IS NOT NULL
    DROP TABLE #SCVTMP_BCUSTOMER
    IF OBJECT_ID('TEMPDB..#PDS_CREATE_SCV_TEMP') IS NOT NULL
    DROP TABLE #PDS_CREATE_SCV_TEMP
    IF OBJECT_ID('TEMPDB..#MASTER_NOTIN_LCSTSA') IS NOT NULL
    DROP TABLE #MASTER_NOTIN_LCSTSA
    IF OBJECT_ID('TEMPDB..#MASTER_NOTIN_LCSTCCG') IS NOT NULL
    DROP TABLE #MASTER_NOTIN_LCSTCCG
    

      

    ALTER TABLE #TEMP3 ADD ID INT IDENTITY(1,1)

    给临时表加上自增ID

  • 相关阅读:
    线程
    网络编程
    正则表达式
    XML
    java----八种排序算法
    Java 关键字 速查表
    Day_19多线程(下)
    Day18_进程(中)
    Day17_进程(上)
    Day15_IO流(上)
  • 原文地址:https://www.cnblogs.com/qianjinyan/p/10271916.html
Copyright © 2011-2022 走看看