Iif Statement

T

Thorson

I am trying to write an Iif Statement for a query but I am not sure how to do
it. I have two tables in my query, one for the dam (mother) and one for the
sire (father). I want it so that if the color of the dam and father both =HB
then the column will put HB otherwise leave blank.
 
J

John Spencer MVP

Probably something like the following

IIF([TableNname].Dam="HB" and [OtherTable].Sire="HB","HB",Null)

John Spencer
Access MVP 2002-2005, 2007-2009
The Hilltop Institute
University of Maryland Baltimore County
 
T

Thorson

Works great! Thanks
--
Thorson


John Spencer MVP said:
Probably something like the following

IIF([TableNname].Dam="HB" and [OtherTable].Sire="HB","HB",Null)

John Spencer
Access MVP 2002-2005, 2007-2009
The Hilltop Institute
University of Maryland Baltimore County
I am trying to write an Iif Statement for a query but I am not sure how to do
it. I have two tables in my query, one for the dam (mother) and one for the
sire (father). I want it so that if the color of the dam and father both =HB
then the column will put HB otherwise leave blank.
 

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