Results 1 to 5 of 5
  1. #1
    Ricardobalbio is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    May 2013
    Posts
    3

    Algorithm for program maintenance

    Hello,

    I need to develop a query where I put the hour meter machine and know when it's time to perform maintenance. The problem is that if I simply subtract one from the previous hour meter, I did not know if it is necessary to maintain longer periods.



    Example: With 210 hours of work I have to do the maintenance of 50, 100 and 200 hours. But with 260 I have to do with only the 50 hours maintenance. And with 310 I have to do the maintenance of 50,100 and 300.

    Can anyone help me?Hello,

    I need to develop a query where I put the hour meter machine and know when it's time to perform maintenance. The problem is that if I simply subtract one from the previous hour meter, I did not know if it is necessary to maintain longer periods.

    Example: With 210 hours of work I have to do the maintenance of 50, 100 and 200 hours. But with 260 I have to do with only the 50 hours maintenance. And with 310 I have to do the maintenance of 50,100 and 300.

    Can anyone help me?

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,642
    Is there a reason you duplicated your question?

    I have a vehicle maintenance db that probably has similar requirements. I use a "required maintenance" table that would list the vehicle, the type of service, and the interval. I also have a maintenance table where the date, mileage and type of service would be recorded. There is also a vehicle table where the odometer is kept updated through automated processes. From those, I can look up the last service of a given type, get the interval and add it to the last service, compare the result to the current odometer to determine whether or not it's due.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    Ricardobalbio is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    May 2013
    Posts
    3
    Yes, But I need an Algorithm that doesn't need the historical. Because I can't trust in the historical database for my case.

  4. #4
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,642
    How would you know at 310 that the 300 maintenance wasn't done at 300, or 305, or whatever? I don't know how you do it without the history.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  5. #5
    Ricardobalbio is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    May 2013
    Posts
    3
    Actually, I just have the last maintenance.

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

Similar Threads

  1. Replies: 14
    Last Post: 02-08-2013, 03:06 PM
  2. Maintenance Database
    By shariq1989 in forum Database Design
    Replies: 1
    Last Post: 06-28-2012, 04:55 PM
  3. Program a 30-day trial into my Access Program?
    By genghiscomm in forum Programming
    Replies: 1
    Last Post: 05-26-2011, 02:14 PM
  4. algorithm for encoding password string
    By princess-1 in forum Security
    Replies: 2
    Last Post: 10-30-2010, 05:48 PM
  5. Creating an algorithm function.
    By NGLG in forum Access
    Replies: 0
    Last Post: 12-07-2008, 09:57 PM

Tags for this Thread

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