Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Causes of Incorrect Syntax near else

Author  Topic 

mj
Starting Member

25 Posts

Posted - 2001-08-28 : 16:48:08
I finally got the sproc developed that I posted about earlier, now I want to expand it to add functionality to it. It goes like this:

if @FieldValue in (Select List)
Begin
--do statements
end
else --- here is where I am getting an incorrect syntax near else. The last statement before the else is an 'end'. the syntax works fine if I don't have the else in there. I checked BOL, and the syntax appears to be correct. I'd appreciate any suggestions any has to offer, and if asked, I will post the sproc here. I don't want to now because it is like 150 lines long

thanks,
mj


   

- Advertisement -