Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Adding on a certain date 1

Status
Not open for further replies.

morristk

IS-IT--Management
Apr 30, 2004
9
I am building a database to track vacation hours and sick leave for employees. Our employees accrue a certain amount of hours each month for their leave.

Does anyone have any ideas how I can create a query that will automatically add X number of hours to a leave balance say on the first of each month??

I don't have a clue where to start. Thanks for any help you can give!
 
morristk,
Assuming that your employees accrue leave at different rates, you will need to store that value for each employee in their data somewhere.

Then you can create a scheduled task in Windows that runs whenever it's appropriate (say, the first day of each month, or whatever--see Control Panel Scheduled Tasks). The scheduled task runs a .bat file that kicks off your Access database with a command line argument (see startup command-line options in Access documentation) to run a bat file that starts Access and fires off a macro (see the "x" argument of the command line) that runs the update query.

It sounds more complicated than it is.

Tranman



"Adam was not alone in the Garden of Eden, however,...much is due to Eve, the first woman, and Satan, the first consultant." Mark Twain
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top