Dates

  • Thread starter Thread starter Kim
  • Start date Start date
K

Kim

I am using the 2000 Access Program.

I have a query to identify employees with seniority dates
that as of Dec 2004 will be celebrating their 5, 10, 15,
20 or 25 years of seniority. In one field [Sen] is this
formula: Sen: (#12/31/2004#-[HDATE])/365.25). This
calculates the Seniority Years OK. But how do I get the
report to only pull those records with the 5, 10, 15 etc
years of seniority. I tried several formulas but could
not get what I wanted.

Can anyone help me? Kim
 
Although I doubt the total accuracy of your calculation, you could use

Field: Sen: Int(#12/31/2004#-[HDATE])/365.25) Mod 5
Criteria: 0

That will give you everyone that has a five year anniversary, but it will also
return those that have just been hired in 2004 so you would need to add one
other criteria to your query.

Field: HDate
Criteria: <#1/1/2000#

That will exclude anyone that has been hired in the last 4.99 years (approximately).
 
Back
Top