|
|
|||||||||
|
|||||||||
|
|||||||||
| |
||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Syntax error keyword 'where'
Hi guys,
I am using SQL 2000 server on a windows 2000 server. I have store procedure that was working and now it is giving me an error. The error I get is the following: [Microsoft][OBDC SQL Server driver][SQL server]incorrect syntax near the keyword 'where' Does anybody know how to fix this? Thanks a lot. |
|
#2
|
||||
|
||||
|
Post the code for your stored procedure, there may be something misspelled, a comma out of place or something like that.
|
|
#3
|
|||
|
|||
|
Sorry
Sorry i forgot the coding. One more clue. I get error when i try to see the BINDINGS in Dreamweaver 2004. I don't get the error in the SQL server.
CREATE PROCEDURE [dbo].[CityStateResultBasic] @varCity varchar (50), @varState char (2) AS begin if (@varCity != 'a' and @varState != 'b') begin SELECT City, State, ZipCode, TypeofHouse, Sqft, NumberofBeds, Price, NumberofBaths,PropertyID FROM dbo.tbl_total_prop_info WHERE City = @varCity and State = @varState end else if (@varCity = 'a' and @varState !='b') begin SELECT City, State, ZipCode, TypeofHouse, Sqft, NumberofBeds,Price,NumberofBaths, PropertyID FROM dbo.tbl_total_prop_info WHERE State = @varState end end GO |
|
#4
|
||||
|
||||
|
Syntax seems ok, I've never used Dreamweaver, but it could be something wrong there. perhaps you might post some of your Server Side code (JSP, ASP ect...).
|
![]() |
| Viewing: ASP Free Forums > Database > Microsoft SQL Server > Syntax error keyword 'where' |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|