Query in database

Solved/Closed
paul - Aug 9, 2010 at 02:11 AM
 paul - Aug 10, 2010 at 03:03 AM
Hello,

my name is paul.. i just want to know if it is possible to query on sql server and in access 2007.. i am doing an election system.. im wondering on how can i count the votes of single person only.. tnx all answers were highly appreciated..

1 reply

rizvisa1
Posts
4479
Registration date
Thursday January 28, 2010
Status
Contributor
Last seen
May 5, 2022
769
Aug 9, 2010 at 02:33 PM
Yes you an query any database (if you have permissions to tables and columns)

How can you get a count depends the structure of the table


SELECT PERSON_ID, count(*) from mytable group by PERSON_ID

this statement is grouping data on a column person_id, and for each person_id gives you a total

This is just an example. The sql depends on table layout.
1
thanks for your help... i think ive already encountered this statement... thanks to you now i remember... :)
0