Home  >  Article  >  Database  >  T-Sql-事务(Transaction)

T-Sql-事务(Transaction)

WBOY
WBOYOriginal
2016-06-07 17:42:45913browse

今天讲下T-Sql语法中事务的用法,事务在项目中一般用的很少,主要用于转账,或是一些多表操作,第一步完成不了滚回,不执行接下的步骤。要么都不完成要么都完成,这是事务的特征。 语法很简单,示例代码如下: Transaction_9_30 2 use Transaction_9_30 Zang

  今天讲下T-Sql语法中事务的用法,事务在项目中一般用的很少,香港服务器,主要用于转账,美国空间,或是一些多表操作,第一步完成不了滚回,不执行接下的步骤。要么都不完成要么都完成,这是事务的特征。

  语法很简单,美国服务器,示例代码如下:

Transaction_9_30 2 use Transaction_9_30 Zanghui Jago Jago.Zhanghui 6 ( , ) Jago.Zhanghui(ID,Balance) values(1,1000); Jago.Zhanghui(ID,Balance) values(2,3000); ID=1; ID=2; Jago.Zhanghui t1; ; ; ID=1; (Jago.Zhanghui where ID=1) ; ; ID=2; (Jago.Zhanghui where ID=2) ; () t1; t1;

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn