By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,479 Members | 1,245 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,479 IT Pros & Developers. It's quick & easy.

Counting up appointments in a day

P: 1
Hello, im not very good at access, and i have a question if you guys could help.

For my database i have one column in one table with all the appointments that have ever been made, and i need to create a form or query to calculate how many appointments have happened each day.

Any help would be vastly appreciated thank you
Jun 8 '07 #1
Share this Question
Share on Google+
1 Reply

MSeda
Expert 100+
P: 159
You just need a simple crosstab query
the SQL will look more or less like this.
Expand|Select|Wrap|Line Numbers
  1. TRANSFORM Count([ApptTable].[ApptID]) AS [CountofApptID]
  2. SELECT [ApptTable].[ApptDate]
  3. FROM [ApptTable]
  4. GROUP BY [ApptTable].[ApptDate]
  5. PIVOT "Count";
  6.  
choose your appointment table in the query builder and then select crosstab as the query type choose The date field and set that as the row heading choose the PK field and set that as the value and choose count as the funcion then enter somthing like CountAppt: "Count" and set that to the column heading
Jun 14 '07 #2

Post your reply

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