Link to home
Start Free TrialLog in
Avatar of lancerxe
lancerxe

asked on

SINTAX ERROR IN SP

HELLO EXPORTS. ATTACHED IS THE SP I'M HAVING TROUBLE WITH.
THANKS  
SP.txt
Avatar of rajvja
rajvja
Flag of United Kingdom of Great Britain and Northern Ireland image

Hi,

   Which line you are getting error. I guess, the syntax for identity column is Id INT IDENTITY(1,1) NOT NULL PRIMARY KEY

If not, post the line
Avatar of lancerxe
lancerxe

ASKER

IF (@Project  = 'SmartCare')
Where is the END statement for WHILE loop
error mesaage
Msg 156, Level 15, State 1, Procedure usp_QA_Defects_1_Business_Area, Line 80
Incorrect syntax near the keyword 'IF'.
Msg 156, Level 15, State 1, Procedure usp_QA_Defects_1_Business_Area, Line 110
Incorrect syntax near the keyword 'AND'.
Hi,

      INSERT STATEMENT should be inside IF STATEMENT

Otherwise it is assuming that VALUES caluse but fount IF statement
ASKER CERTIFIED SOLUTION
Avatar of rajvja
rajvja
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
i will try that. thanks rajvja.