Results 1 to 7 of 7
  1. #1
    4 Star Lounger
    Join Date
    Feb 2002
    Posts
    537
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Set after 3 months (Access 2000)

    Can i set the Yes/No value of a filed to No after three months starting from the field LastUpdated? I have both these field in the table but i need to set the value of the field Skonto to No after three month's time

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Set after 3 months (Access 2000)

    Wouldn't that change the LastUpdated value to the current date?

    If the purpose of the Yes/No field is merely to indicate whether three months have passed since the LastUpdated date, it shouldn't be a field in the table since it is derived information. You can use a query to calculate it without storing the value in the table.

  3. #3
    4 Star Lounger
    Join Date
    Feb 2002
    Posts
    537
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Set after 3 months (Access 2000)

    Not all the customers get the Skonto.They get it under special conditions and then we mark them with Yes for Skonto.But this Skonto lasts for thee months only and then they loose the riht to get the Skonto. So after three months each the Skonto will be marked to No again for that particular customer.The field LAtUpdated need not tbe changed, i think it could serve me to calculate the three months period only

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Set after 3 months (Access 2000)

    You still don't need a field in the table for this. You can calculate in a query whether the customer gets a discount or not. But I wouldn't use the LastUpdated field for that, if that means what I think it means.

  5. #5
    4 Star Lounger
    Join Date
    Feb 2002
    Posts
    537
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Set after 3 months (Access 2000)

    Maybe you are right.Iam not sure how to do it.The yes/no field for a skonto is a secondary field ( we have another field for the real discount) actually detemining the involvemnet of the employee , it ia s kind of bonus and is not given for all the customers.If once we have decided to designate the customer with yes, the renumeration should be received not more thsn three months. But how could i calculate the beginning of the date, i am not sure

  6. #6
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Set after 3 months (Access 2000)

    Instead of a Yes/No field, you could use a Date/Time field StartSkonto. When the "skonto" is awarded, the employee enters the current date (or the date the skonto starts).
    In a query based on the table, you can add the following condition for the StartSkonto field in the Criteria line:
    <code>
    Between DateAdd("m", -3, Date()) And Date()
    </code>
    If the StartSkonto field is blank, it doesn't meet the criteria. If it is more than 3 months before the current date or after today, it doesn't meet the criteria either.

  7. #7
    4 Star Lounger
    Join Date
    Feb 2002
    Posts
    537
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Set after 3 months (Access 2000)

    Dear Hans, i owe you an explanation.It turns out that i need a modification in the database although i will use the main critetria again.But the terms of usage will not be the time per months but only the first two times . I will open a new thread for that since from an Access point of view it will be an entierly differen question. But i wanted to inform you the reasons for that. You helped me a lot and i owe you this explanation

Posting Permissions

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