Compare two columns in same table; result in 3 column

T

Trisha

I need some assistance on how to perform the following in MS Access..

I have a query (Query A) and it contains data from two to other tables. I
need to compare the data from the two and in the 3rd column report true or
false (true = they match).

Example:

CUS_XID_CUST_ID, cExternalID, VALIDATION

If CUS_XID_CUST_ID = cExternalID then VALIDATION = TRUE ELSE FALSE

How do I place this into my query?

Thanks!
 
R

RonaldoOneNil

In the 3rd column of your query design grid put this
VALIDATION: IIf(CUS_XID_CUST_ID = cExternalID,True,False)
 
T

Trisha

Thanks Ronald. When I put this in there it seems to be working but it is
prompting me to enter a value.

It brings up an 'Enter Parameter Value' window and is waiting or a response.

Should it not automatically populate the field?
 
R

RonaldoOneNil

Enter parameter value is usually because of a typing error in your
expression. Check the field names in your expression match the field names in
your table. The field that it is prompting for should be shown just above the
input box area.
 
T

Trisha

Thank You. I figured it out. I was entering the conditions in the wrong
field. It is now working.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top