Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

How do I calculate  salary increase and elapsed time between....

Posted on 2008-06-24
12
Medium Priority
?
1,270 Views
Last Modified: 2013-12-27
Hi,
I am faced with a scenario in finding an employee's salary increase, both in dollars and as a percentage of the previous salary. Calculate how long the employee had towait for that increase and how much time has elapsed between the present and previous salary.
I am new to access and would be happy to learn from your expertise.
0
Comment
Question by:meena_26
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 5
12 Comments
 
LVL 7

Expert Comment

by:Chrisedebo
ID: 21854252
Do you have a table containing the correct information? ie employee, salary, date salary valid from,  etc
0
 

Author Comment

by:meena_26
ID: 21854295
Hi Chrisdebo:
Yes, I do have a simple table wherein there's a list of emloyee, salary, hired date, salary effective date. My problem is, how to calculate employee's salary both in dollars and percentage of the previous salary. And to calculate how long the employee had towait for that increase and how much time has elapsed between the present and previous salary.
Looking forward to your solution. Thanks!
0
 
LVL 7

Expert Comment

by:Chrisedebo
ID: 21854333
Does this table contain multiple rows for each employee? ie a new row is added each time an employee is given a pay rise.
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 7

Expert Comment

by:Chrisedebo
ID: 21854377
Can you give me a sample of the table to work with?
0
 

Author Comment

by:meena_26
ID: 21855119

I am jst given a scenario in here wherein I am going to track employee compensation. I am asked to find a lot of stuff like age of every employee as well.  So, I started by making a table first with EmployeeID, LastName, FirstName, Birthdate,HiredDate, PresentSalary, PreviousSalary, PresentSalaryEffectiveDate and PreviousSalaryEffectiveDate. I don't have any values in each given field but i need to calculate age, length of service, most recent salary increase both in dollars and as a percentage....
First, I created a table, then a query, then a form. the problem is how to calculate them,
I hope i answered your question; you got my full cooperation to solve this matter.
0
 
LVL 7

Expert Comment

by:Chrisedebo
ID: 21855278
If all the information is contained in one row in the SQL table then it should just be a case of doing some simple calculations.

Eg.
Select FirstName + ' ' + LastName as Employee, 
   datediff(y,birthdate,getdate()) as Age,
   datediff(y,hireddate,getdate()) as LengthOfService,
   PresentSalary - PreviousSalary as SalaryRise,
   ((PresentSalary - PreviousSalary)/PreviousSalary) * 100 as SalaryRisePerCent
From EmployeeDetails

Open in new window

0
 
LVL 7

Accepted Solution

by:
Chrisedebo earned 1500 total points
ID: 21855299
Sorry, just noticed that you're using access.....
Select FirstName & " " & LastName as Employee, 
   datediff("yyyy",birthdate,getdate()) as Age,
   datediff("yyyy",hireddate,getdate()) as LengthOfService,
   PresentSalary - PreviousSalary as SalaryRise,
   ((PresentSalary - PreviousSalary)/PreviousSalary) * 100 as SalaryRisePerCent
From EmployeeDetails

Open in new window

0
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 21855395
...just use Date() instead of getDate() . Access doesn't recognize getDate() function
0
 
LVL 7

Expert Comment

by:Chrisedebo
ID: 21855403
D'oh! Thanks capricorn.....
0
 

Author Comment

by:meena_26
ID: 21858795
Thanks, guys. I just wonder, should i just type in the formula to the table?Or should I do it on the Form?It's my very first time to use Access and you have been  a great help.
P.S. How to determine employee's recent performance given the data above?
0
 

Author Comment

by:meena_26
ID: 21858891
is this the right way to solve the time elapsed between the present and previous salary?: PresentSalaryEffectiveDate-PreviousSalaryEffectiveDate
0
 

Author Closing Comment

by:meena_26
ID: 31470076
Hi. Thanks for helping me out.
0

Featured Post

Reclaim your office - Try the MB 660 headset now!

High level of background noise often makes it difficult for employees to concentrate fully on their jobs – or to communicate clearly on calls. The MB 660 headset helps you create a disruption free workspace.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
New style of hardware planning for Microsoft Exchange server.
In Microsoft Access, learn the trick to repeating sub-report headings at the top of each page. The problem with sub-reports and headings: Add a dummy group to the sub report using the expression =1: Set the “Repeat Section” property of the dummy…
With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question