zoukankan      html  css  js  c++  java
  • [转]SQL事务回滚

    create   proc  
      ...  
      as  
      begin  
          set   xact_abort   on     --设置出错时自动回滚事务 
          begin   transaction    
           
          insert   tabel1   vaule(...)  
          if   @@error<>0   then  
          begin  
              rollback   transaction  
              return  
          end  
          insert   tabel2   vaule(...)  
          if   @@error<>0   then  
          begin  
              rollback   transaction  
              return  
          end  
           
          commit   transaction  
          return 
  • 相关阅读:
    微信消息类型和事件类型
    lnmp环境搭建脚本
    laravel框架踩过的坑
    vue结构详解
    PHP消息队列实现及应用
    laravel 运行错误
    笔记分享
    cf730e
    cf 730i
    cf 731f
  • 原文地址:https://www.cnblogs.com/cxy521/p/1048280.html
Copyright © 2011-2022 走看看