Search
 
SCRIPT & CODE EXAMPLE
 

SQL

tsql try catch

BEGIN TRY  
     { sql_statement | statement_block }  
END TRY  
BEGIN CATCH  
     [ { sql_statement | statement_block } ]  
END CATCH  
[ ; ]

-- ex:
BEGIN TRANSACTION
BEGIN TRY

UPDATE users SET id = 0

END TRY
BEGIN CATCH

ROLLBACK

END CATCH

COMMIT
Comment

PREVIOUS NEXT
Code Example
Sql :: sql get tables from current database you working with 
Sql :: sqlite create integer column with limit 
Sql :: hexadec to sql REDSHIFT 
Sql :: Odoo Service is not coming up with postgresql read replica (slave) 
Sql :: check sql database table lock 
Sql :: oracle synonym 
Sql :: wordpress sql change site url 
Sql :: mysql bidirectional composite primary key 
Sql :: dual table in aql 
Sql :: for loop postgresql 
Sql :: sql syntax find few columns 
Sql :: postgresql create table with timestamp 
Sql :: mysql column start with string 
Sql :: update substring in mysql 
Sql :: create policy in sql 
Sql :: oracle export view ddl 
Sql :: select insert new table sql server 
Sql :: how do you use sql in you company 
Sql :: t-sql select min from two values 
Sql :: oracle current date plus 1 month 
Sql :: drop table sql 
Sql :: delete all table oracle 
Sql :: how to add not null constraint in sql 
Sql :: how to get slow query log in mysql 
Sql :: date to string sql 
Sql :: create table sql 
Sql :: ostgreSQL version 
Sql :: sql auto timestamp 
Sql :: data directory postgresql 
Sql :: mysql remove only_full_group_by permanently 
ADD CONTENT
Topic
Content
Source link
Name
5+1 =