1 CREATE PROCEDURE [dbo].[PL_GEN_PROVN_NO1]
2 @GAD_COMP_CODE VARCHAR(2) =NULL,
3 @@voucher_no numeric =null output
4 AS
5 BEGIN
6
7 begin try
8 -- your proc code
9 end try
10
11 begin catch
12 -- what you want to do in catch
13 end catch
14 END -- proc end
15