472,096 Members | 2,215 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,096 software developers and data experts.

help with sql server select statement

i am trting to count how many people answered yes in question cause i am running questionniare for my company using sql with .net

Select COUNT (*) as Q7 FROM IOLS_Quest1 WHERE Q7 = 'Yes'

error massage Msg 102, Level 15, State 1, Line 11
Incorrect syntax near 'IOLS_Quest1'.
Mar 12 '08 #1
2 952
davidson1
144 100+
Try this

Select COUNT (*) FROM IOLS_Quest1 WHERE Q7 = 'Yes'

Davidson
Mar 12 '08 #2
i am trting to count how many people answered yes in question cause i am running questionniare for my company using sql with .net

Select COUNT (*) as Q7 FROM IOLS_Quest1 WHERE Q7 = 'Yes'

error massage Msg 102, Level 15, State 1, Line 11
Incorrect syntax near 'IOLS_Quest1'.
The statement you entered here looks sufficiently correct, but I'm assuming you retyped it, because the word "message" is incorrectly spelled here, and the error message refers to Line 11 in your code. Can you copy and paste the actual code that is sent to the SQL server?
Mar 13 '08 #3

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

28 posts views Thread by stu_gots | last post: by
8 posts views Thread by db2sysc | last post: by
6 posts views Thread by Twobridge | last post: by
15 posts views Thread by Jay | last post: by
6 posts views Thread by zaina | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.