Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Grouping by month

Status
Not open for further replies.

1510982

Programmer
Feb 17, 2002
57
SI
Hi.
I have a birthday record fro which type is Date. How can I now Group and Count those records by the month they were born?

eg. january: 14
february: 22
...

10x for your kidness.
 
You could use a crosstab query to display the number of birthdays for each month. Use the crosstab wizard, which is very good in situations like this.

Iain Robbo ;-)
 
Yes, on a report. I'll try to check the crosstab wizard, as soon as I find out what it is ;)
I'll let you know the solution, l8r.
 
You should just let the report do all the work.

Create a group in the Grouping/Sorting form that will evaluate to the month number (=Month([your date column])) and make sure Group Header is Yes and Group Footer is Yes.

This will sort and group them by month (Jan is 1 Feb is 2...)
In the group Header, you can format the [your date column] to show the Month name (=Format([your month column],"mmmm")).

In the group footer, create a text box that will sum or count the column you need for the month (=Sum([your column])).
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top