my employee listing

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

hey all,

i have a table of employees and what i'd like to do is group by male and
female. but also would like a count of which employees fall in a specific age
range.

I know how to do the first grouping but how would i do the 2nd one?

thanks,
rodchar
 
What good does it do you to know the genders and birthdays if you don't know
who the people are?
 
census info. for the State Dept. of H.R.


Amy Blankenship said:
What good does it do you to know the genders and birthdays if you don't know
who the people are?
 
First, I'd do something like this:

Select DateDiff("yyyy", Date(), Birthday) AS Age, Gender FROM CensusData

Save that query as qryAgeGender

To get your aggregation from that data, you can apply the concepts from this
video.
http://www.datapigtechnologies.com/flashfiles/crosstab.html

If you need more specifics on how to apply the concepts, post back.

HTH;

Amy
 
Of course, that won't be a completely correct age: it will say people are
older than they are if they haven't already had their birthday.

Select DateDiff("yyyy", Date(), Birthday) - IIf(Format(Date(), "mmdd") <
Format(Birthday, "mmdd"), 1, 0) AS Age, Gender FROM CensusData
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top