Results 1 to 3 of 3
  1. #1
    mws5872 is offline Novice
    Windows XP Access 2003
    Join Date
    Jun 2009
    Posts
    11

    update query

    I have a fairly simplistic update query I want to create.

    I figured it is best to do an IIF statement something like this.



    IIf([TR by Region]![Segment]='ABF,'ABF',IIf([TR by Region]![Segment]='Mortgage','Mortgage'))

    now that last part is a little tricky for me. If it does NOT match either of these values I want it to keep the field value it currently holds any ideas?

  2. #2
    ConneXionLost's Avatar
    ConneXionLost is offline Simulacrum
    Windows XP Access 2003
    Join Date
    Jan 2010
    Location
    Victoria, Canada
    Posts
    291
    Based on what you've got so far in the Iif statement, as well as what you say you want it to do, you should get rid of the Iif statement altogether because you don't need one.

    Cheers,

  3. #3
    mws5872 is offline Novice
    Windows XP Access 2003
    Join Date
    Jun 2009
    Posts
    11
    I think I am confusing you... if field A contains either of these then field b needs to be over written with what is is field a( update field b) if it does not match either of these field b needs to remain the same.

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

Similar Threads

  1. Update Query
    By Lockrin in forum Queries
    Replies: 7
    Last Post: 04-15-2010, 08:59 AM
  2. Update Query
    By vvasudev in forum Queries
    Replies: 0
    Last Post: 11-10-2009, 01:32 AM
  3. Update Query- selective update?
    By stephenaa5 in forum Queries
    Replies: 1
    Last Post: 10-29-2009, 11:15 AM
  4. Help with update query
    By weirdg in forum Queries
    Replies: 0
    Last Post: 09-03-2009, 04:21 AM
  5. Need help with an Update query ...
    By valkyry in forum Queries
    Replies: 0
    Last Post: 04-23-2007, 08:45 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