Newbies Turnkey Posted April 28, 2011 Newbies Posted April 28, 2011 I'm just getting started so bear with me. I've just imported a group of employee's who can retire after 25 years of service. I need to calculate the their retirement date and the age they will be when they retire. Thanks, T.
comment Posted April 28, 2011 Posted April 28, 2011 Try: DateOfRetirement = Date ( Month ( DateOfEmployment ) ; Day ( DateOfEmployment ) ; Year ( DateOfEmployment ) + 25 ) AgeAtRetirement = Year ( DateOfRetirement ) - Year ( DateOfBirth ) - ( Date ( Month ( DateOfBirth ) ; Day ( DateOfBirth ) ; Year ( DateOfRetirement ) ) < DateOfRetirement )
Vaughan Posted April 28, 2011 Posted April 28, 2011 I've just imported a group of employee's who can retire after 25 years of service. And then you deport them? Sorry, couldn't resist.
FMPierce Posted September 23, 2011 Posted September 23, 2011 Here is a calc my dad and I made to calculate experation dates. Where: StartDate = date the 25 years starts, Term_Months = number of months in the term (in your case it would be 300, 25 years times 12 months in a year) Let ( [ x = Month ( StartDate ) + Term_Months ; y = Day ( StartDate ) ; z = Year ( StartDate ) ] ; If ( x > 12 ; ( x - 12 ) & "/" & ( y ) & "/" & ( z + 1 ) ; ( x ) & "/" & ( y ) & "/" & ( z ) ) )
comment Posted September 23, 2011 Posted September 23, 2011 Using the Date () function is not only simpler - it also works regardless of the date format in use.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now