User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the MS Access and FileMaker Pro section within the Web Development category of DaniWeb, a massive community of 402,454 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,913 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our MS Access and FileMaker Pro advertiser: Programming Forums

Access If, Then, Else statement - HELP!

Join Date: Jun 2006
Posts: 3
Reputation: yvs is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
yvs yvs is offline Offline
Newbie Poster

Re: Access If, Then, Else statement - HELP!

  #2  
Jun 16th, 2006
Hi, Saundra,

Keeping vacation time with every employee's record does not sound a good idea, because it depends on the time an employee has been
with a company rather then on a particular employee record.
In your example, there will be a group of employees, who has worked for less than 1 year, a group of people who has worked
for 1-2 years, 2+ years and the rest with 5+ years service history.
Besides, if you keep vacation time with the employee record,
WHEN are you going to update the value?
You would not like to have a program running all the time for years
in order to catch the moment. Doing this at the point when you
actually want to check the values will do so every time you open
an employee's record (let's say), which does not make sense either.

I would suggest creating a separate table, which holds correct vacation time for every period, you described. Something like:

Period Vacation time
1 40
2 80
5 120

Then every time you open the employee record, your program will calculate the difference (in years) between the current date and the employee's start date and then return vacation time from the above table. I would do this on "greater then" basis starting from the maximum period.

I hope this helps.




So, your VTBeginningBalance will be a dynamically calculated value
rather then a physical database field.
Reply With Quote  
All times are GMT -4. The time now is 3:32 pm.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC