Results 1 to 2 of 2
  1. #1
    Lorlai is offline Competent Performer
    Windows Vista Access 2007
    Join Date
    Jun 2011
    Posts
    107

    Database Design: Normalize daily scheduled time

    I have a monthly forecast for about 50 employees that I have stored into a table in access. My client would like an interactive form that will allow a user to update the forecast on a daily basis. Currently, the monthly forecast is stored as total hours forecasted for each employees, aggregated by month. I am trying to find a way that will allow me to separate these hours into a daily work day. In general, an employee will work 8 days Mon-Fri, with no hours worked on Saturday or Sunday.

    The current table I have imported from the monthly forecast spreadsheet looks like:

    Forecast_TABLE
    Emp_ID
    Emp_Name
    Month
    Year
    Scheduled Work

    Emp_ID Emp_Name Month Year Scheduled Work
    12345 Joe Jon 07 2013 176
    67890 Dennis Rosmith 07 2013 168

    The above examples demonstrate what the data will typically look like. In general, all employees will work 8 hours every work day in a month. The exception to this is vacation/holiday time. Employee Joe Jon worked 8 hours every work day (Monday - Friday) of the month of July (except for the holiday of July 4), for a total of 176 hours. Dennis Rosmith took one day of PTO (paid time off) after the July 4th holiday, and worked 8 hours every work day except for his PTO day. As such, Dennis Rosmith's total hours for July were 168.



    My client requires that the information be displayed in a spreadsheet form in Access, where each cell is rewritable. They also require the ability to update the scheduled work on a daily basis. A rough draft of this requirements looks like the example below:

    Emp_ID Emp_Name Sunday
    6/30/13
    Monday
    7/1/13
    Tuesday
    7/2/13
    Wednesday
    7/3/13
    Thursday
    7/4/13
    Friday
    7/5/13
    Saturday
    7/6/13
    Sunday
    7/7/13
    Monday
    7/8/13
    Tuesday
    7/9/13
    Wednesday
    7/10/13
    Thursday
    7/11/13
    Friday
    7/12/13
    Saturday
    7/13/13
    Sunday
    7/14/13
    Monday
    7/15/13
    Tuesday
    7/16/13
    Wednesday
    7/17/13
    Thursday
    7/18/13
    Friday
    7/19/13
    Saturday
    7/20/13
    12345 Joe Jon 0 8 8 8 0 8 0 0 8 8 8 8 8 0 0 8 8 8 8 8 0
    67890 Dennis Rosmith 0 8 8 8 0 0 0 0 8 8 8 8 8 0 0 8 8 8 8 8 0

    In the example above, 0 indicates no scheduled hours (or no hours that will be charged to the company) and the 8 indicates the amount of hours scheduled for the day.
    Is there a way to take the monthly total of hours worked, and use that total to display the scheduled hours in the daily format above? Or is there a way to better design the database for this information?

    Thank you for any help you may provide!

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,929
    This would require elaborate VBA code.

    You might find this of interest https://www.accessforums.net/databas...ses-18459.html

    Duplicate thread on same topic is against forum guidelines. I have deleted other thread.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Enter Daily time in Form
    By Lorlai in forum Forms
    Replies: 6
    Last Post: 03-11-2013, 11:00 AM
  2. Normalize a flat database
    By worldwidewall in forum Access
    Replies: 5
    Last Post: 03-23-2012, 04:06 AM
  3. Reporting Time fixed as a daily variable
    By jalal in forum Access
    Replies: 1
    Last Post: 03-19-2012, 04:55 AM
  4. Reporting Time fixed as a daily variable
    By jalal in forum Access
    Replies: 2
    Last Post: 03-17-2012, 08:21 PM
  5. Help starting up a daily entry database
    By sparx in forum Database Design
    Replies: 1
    Last Post: 01-12-2011, 10:56 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums