AnsweredAssumed Answered

Automatically creating records in a vacation table

Question asked by jessieleah on May 12, 2014
Latest reply on Jun 2, 2014 by philmodjunk

Title

Automatically creating records in a vacation table

Post

     I have an employee database.  It contains employees who are salary (paid on the 15th and last day of the month) and hourly employees who are paid bi-weekly.  People employed for 1-6 years and 364 days earn the same amount vacation time regardless of how they are paid.  People employed 7 years or more earn more per pay period regardless of how they are paid.
      
     I have a related vacation table (related by employee number) and currently records are being entered manually for the vacation time they earn each pay period.
      
     I need help.  I'm am sure there is a way to have this information entered automatically like from a script then have it run by FM Server.
      
     I'm not sure how to create the script, it seems very complicated.
      
     I would want a script to run for biweekly paid people
     add record automatically with the amount of time they are currently accruing (there is a field for that)
      
     I would want a script to run for semi-montly people they are paid on the 15th and last day of the month.
     same here, add record automatically with the amount of time they are currently accruing.
      
     Vacation table:
     It is a relatively new table, I have the following fields in the table
      
     StartAccured (as they all had some accrued prior to this table being built) this field is also used to enter the amount they get every pay period and there is a summary of what they have accrued all together
      
     VacationStart and VacationEnd which calculates the number of days taken (VacationTaken) which is subtracted from what they have earned (VacationAvailable)
      
     The table has a field for the amount they earn per pay period (VacationRate) and also does a lookup of their pay schedule (PaySchedule) when a record is created
     I had created the two field in trying to created the scripts to automatically add records.
      
     However, it is too complicated for me to even begin as I don't even know how to create a script that would run bi-weekly or semi monthly let alone add records and automatically enter their vacation accrual rate based on the VacationRate field
      
     Anyone up for the challenge of helping me with this one?
      
     Thanks and have a good day!

Outcomes