I am getting an error message with the error handling I just added to this stored procedure anyone know why
Code:
SET QUOTED_IDENTIFIER ON
GO
SET ANSI_NULLS ON
GO
ALTER PROCEDURE dbo.[SURVEILLANCE-VBM]
AS INSERT INTO dbo.GCEmployeeTerms
([TM #], FirstName, LastName, SocialSecurityNumber, TerminationDate, Title, DepartmentName)
SELECT [TM #], FirstName, LastName, SocialSecurityNumber, TerminationDate, Title, DepartmentName
FROM dbo.Termination_View
WHERE (DepartmentName = N'SURVEILLANCE - VBM')
GO
SET QUOTED_IDENTIFIER OFF
GO
SET ANSI_NULLS ON
IF @@ERROR <> '0'
GO
[\code]
this is the error message I am getting
Server: Msg 170, Level 15, State 1, Line 2
Line 2: Incorrect syntax near '0'.