I have what I think should be a simple question but for the life of me cannot solve it myself. I'm just trying to do a simple search on a table.
Select *
From dbo.Case
Where dbo.Case.CountyName='Milwaukee'
I keep getting this error:
Msg 156, Level 15, State 1, Line 2 Incorrect syntax near the keyword 'Case'.
I've also tried taking off the "dbo" and it still does not work.
What am I doing wrong? (Using SQL Server 2008)
CASE is a reserved keyword. You will need to enclose it in [] to use as a an identifier such as a database, column, or table name:
Select *
From dbo.[Case]
Where dbo.[Case].CountyName='Milwaukee'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With