Solved

help with If record appears then this, else that

Posted on 2013-06-14
3
190 Views
Last Modified: 2013-08-13
I have the following data for which I need an iif function and can't quite figure out the syntax.

data:
Name
John Smith
Joe Blow

this data changes so tomorrow it may be
Name
Greg Smith
Jane Doe

I need an iif statement that will do the following:

iif ([name]="John Smith", "Update", "ADD")

the problem i'm having is I ONLY want to do this for John Smith.  I can't set the criteria of [Name]="John Smith" because that defeats the purpose of the iif statement..

basically, if John Smith appears today, regardless of who else is in the field today, then I want to update another field but if John Smith does not appear today I want to add the field.

I hope that's not confusing and appreciate your help.
0
Comment
Question by:intsup
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 40

Accepted Solution

by:
als315 earned 250 total points
ID: 39248460
Will be better if you upload samble DB. An idea may be following: add query with date and Name with criteria ="John Smith". Join your table and this query by date field and update data
0
 
LVL 31

Assisted Solution

by:Helen_Feddema
Helen_Feddema earned 250 total points
ID: 39249281
What do you mean by "the data changes"?  Are records overwritten with new data, are new records added, or what?  Is the data filtered somehow?  What does it mean for "John Smith" to appear today?
0
 

Author Closing Comment

by:intsup
ID: 39406300
I had to seek a different solution so am closing this one
0

Featured Post

Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

756 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question