Advertisement
S_Madanska

@@trancount

Nov 14th, 2021 (edited)
341
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. PRINT @@TRANCOUNT  
  2. --  The BEGIN TRAN statement will increment the transaction count by 1.  
  3. BEGIN TRAN  
  4.     PRINT @@TRANCOUNT  
  5.     BEGIN TRAN  
  6.         PRINT @@TRANCOUNT  
  7. --  The COMMIT statement will decrement the transaction count by 1.  
  8.     COMMIT  
  9.     PRINT @@TRANCOUNT  
  10. COMMIT  
  11. PRINT @@TRANCOUNT  
Advertisement
RAW Paste Data Copied
Advertisement