Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SQL "IN" Not Working

Status
Not open for further replies.

Paully1999

Programmer
Nov 29, 2000
6
US
I have a select statement that works fine with ACCESS from ASP but I'm trying to migrate to SQL Server 2000 and I'm getting an error with the folowing statement

SELECT Zip, Search_Id, State, City, Company_Name, WorkType1, banner, bold FROM ContractorsOnly WHERE (WorkType1 = 'C' or WorkType1 = 'B') AND Zip IN ('60007','60101','60107','60126','60148','60153','60155','60160','60164','60171','60181','60185','60186','60187','60188','60193','60513','60515','60525','60534','60561','60563','60565','60656',) ORDER BY Company_Name

It is erroring out at that IN

Any thoughts????
 
Hiya.
You have an invalid comma after the last value in your 'IN' clause. This might be the only problem.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top