What is difference between tran
and transaction
in SQL Server 2005 ?
Following are two statements
Begin Tran
Begin
.........
.........
End
Rollback
OR
Begin Transaction
Begin
......
......
End
Rollback
What is difference between tran
and transaction
in SQL Server 2005 ?
Following are two statements
Begin Tran
Begin
.........
.........
End
Rollback
OR
Begin Transaction
Begin
......
......
End
Rollback
3条答案
按热度按时间8e2ybdfx1#
There is a slight difference, the functionality is the same for both begin tran and begin transaction.
If you were to add BEGIN TRANSACTION (or BEGIN TRAN) before the statement it automatically makes the transaction explicit and holds a lock on the table until the transaction is either committed or rolled back.
kknvjkwl2#
There is no difference.
TRAN
is merely an allowed abbreviation, as can be seen from the documentation :Syntax
The
{ | }
in this syntax description means 'pick one of these two alternatives'nx7onnlm3#
They are synonymous in Transact SQL, it seems that the same logic have been implemented in MDX...