Results 1 to 4 of 4
  1. #1
    Join Date
    Feb 2004
    Location
    Wales
    Posts
    343

    Unanswered: Automated date generation

    Seasons greetings everyone....tis good to be back since July..

    Working away a usual I came across an interesting request. My client wants to set up an automated date generation system for a monitoring areas of their workplace.

    To expalin these areas having undertaken a monitoring visit are grade High, Medium or low risk. having undertaken an initial inspection and determined the risk category the client wants to enter the initial inspection date and then depending on the "risk level" have access work out the next visit dates. I though it could be done using (psydocode here) if banding 2 then add weeks to the date. Then I would need to place a further date against the generated on up to 2 years hence.

    Then
    If the grading was changed on the next vist reclculate according to the params of the new banding and the last visit date

    To be truthful - I havent the foggiest how to get anywhere near the first operation. The second I know once I have the trigger will come naturally as it appears to be a similar process.

    I know people like to see where your up to so far - And under normal circumstances I would be able to shopw this BUT Im completly in the dark this time -

    anyone ever undertaken something lie this before that could give a failing person a guide where to go with this ??

    Gareth

  2. #2
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    depends
    are yoiu using JET as your data stroage.. if so take advantage of the way JET stores dates adding 1 to a current date gives a date + 1 day

    so you could store the current test date
    store a review code, and int he review code table define how many days that code is valid for, or when that test should be reviewed.

    joining the tables together should give a new test date.

    other db storage mechanism use different techniques or methods to stroe dates.

    I wouldn't store the next review date.. just the last inspection date + what type of risk it is.. form that you know when the next test is due. the one potential problem i can see is if say the inspection regime allows a test to be done, but to run form some unspecified date....

    ....the reason, say someone decides to chaneg the risk inspection interval, and decides High Risk must be inspected every 6 months.. changing the value in the risk type table means you don't have to chaneg data to get the next test date..

  3. #3
    Join Date
    Feb 2004
    Location
    Wales
    Posts
    343
    Well Healdem I cant fault that advice....

    Id say just about smacks me in the face. why I was keeping that forward date recording in my head as having to populate a record I do not know!!

    I will immeadiately go and headbut a wall for being so stupid.


    As always - I thank you ( and I sit here totally embarressed at make a clown of myself) lol

    Thanks for helping me sort my head out.

    Merry Christmas........

    Gareth

  4. #4
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    Quote Originally Posted by garethfx
    ....I will immediately go and headbut a wall for being so stupid....
    we all do it sometimes, at a previous place of work we had a "slaphead of the month" award awarded for outstanding contributions to project development, the wrinkle being you had to nominate yourself, you had to make your presentation od why it was more outstandingly dumb thatn others at a the monthly review in a near by bar.

    Quote Originally Posted by garethfx
    ...I sit here totally embarressed at make a clown of myself
    thats what Christmas is all about.. you are just getting some practise in early.. old stagers, such as myself don't need the practise, we just are emabarrassing all year round.....

    Happy Christmas to you too

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •