Results 1 to 9 of 9
  1. #1
    buck is offline Novice
    Windows 8 Access 2010 64bit
    Join Date
    Dec 2013
    Posts
    26

    Qry Assistance Please

    I have 3 separate queries . . . source is primary table. Each query has a parameter set for Status, L1, L2, or L3.



    At the beginning of the new month, we change all status values to send out second and third reminders. The current process is to run each query and manually type the update from L3 to Loss, L2 to L3, and L1 to L2 so it updates the primary table.

    Is there a way to accomplish this without having to manually type the updates?

    Thanks for your help.

  2. #2
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 7 64bit Access 2010 32bit
    Join Date
    Aug 2013
    Posts
    7,862
    Quote Originally Posted by buck View Post
    ....
    Is there a way to accomplish this without having to manually type the updates?

    Thanks for your help.
    Calculate the updates at the time they are needed and don't try to store calculated values???

  3. #3
    buck is offline Novice
    Windows 8 Access 2010 64bit
    Join Date
    Dec 2013
    Posts
    26
    not sure what you are saying

  4. #4
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 7 64bit Access 2010 32bit
    Join Date
    Aug 2013
    Posts
    7,862
    It is not real clear to me why and what you are updating. Why do you need to transfer information from one table/field to another? What event takes place that you need to update a field to "Loss"? Is this event something that happens inside the DB that can trigger an event handler or function?

    It seems that you have fields in a table populated with historical data. This data then goes through some sort of transition. The result of the transition is stored in another table/field. Is this a calculation? If the historical data does not change, why not apply a formula and use variables to represent the parts that do change. There probably is not any need to store the result.

  5. #5
    buck is offline Novice
    Windows 8 Access 2010 64bit
    Join Date
    Dec 2013
    Posts
    26
    Why I need to update isn't relevent to my request for assistance. I need to know if there is a way to construct a query that will look at a field and if it contains specific values, change it to another designated value. If not possible, I'll work through it.

    Regards

  6. #6
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,726
    If you are sending out reminders, what exactly happens if a recipient responds to a reminder between say L1 and L2. Surely you don't keep sending reminders after someone has responded positively.
    I think there is a part of your process that you haven't mentioned.

    As for your specific question--- paraphrased --- can I change the status of a record from L1 to L2--Yes.

    Update MyTable Set Status = "L2" where status ="L1";

    Good luck

  7. #7
    buck is offline Novice
    Windows 8 Access 2010 64bit
    Join Date
    Dec 2013
    Posts
    26
    is this applied in the query itself or VBA or ???

    Update MyTable Set Status = "L2" where status ="L1";

  8. #8
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,726
    This is the query SQL. Change the name MyTable to the name of your table (and the field name if it isn't Status)

    This query will update the status field to L2 wherever the current status is L1--- Is that what you want?
    Update queries, like Delete queries, are quite unforgiving. Maybe a good idea to backup your table before applying the update.

  9. #9
    buck is offline Novice
    Windows 8 Access 2010 64bit
    Join Date
    Dec 2013
    Posts
    26
    ok thanks.

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

Similar Threads

  1. simple assistance needed
    By gkaro in forum Access
    Replies: 4
    Last Post: 10-17-2013, 11:41 AM
  2. Loop Assistance
    By MegA248 in forum Forms
    Replies: 7
    Last Post: 05-01-2013, 12:24 PM
  3. Assistance with SQL syntax.
    By gm_lowery in forum Access
    Replies: 6
    Last Post: 06-27-2012, 12:07 PM
  4. dlookup assistance
    By underscore in forum Access
    Replies: 4
    Last Post: 12-28-2011, 06:32 AM
  5. Need Assistance with Forms
    By JDA2005 in forum Forms
    Replies: 5
    Last Post: 06-30-2009, 03:37 PM

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