View Full Version : Looooong IIF Statements


Cicely DeMars
07-30-2000, 02:21 PM
I have an IIF() that has to evaluate one of 55 possible entries in the county field, then return one of 18 values in the district field. I tried using the IIF and typing it out, but Access says it is to complex, (not to mention tough to keep track of for me).

ex. IIf([County]="Hancock","1",IIf([County]="Ohio","1"...the false at the end being "Out Of State".

I want to use the IIF(or( . . . but I am unsure of the syntax, could someone post a sample of that so that I can make sense of this. Thank you in advance for any help.
Cic

CWilliams
07-30-2000, 06:11 PM
a case structure would be better here

MikeAngelastro
07-30-2000, 06:18 PM
You may want to try a CountyDistrict table containing two tables:
County
District

Then make both fields keys.

MikeAngelastro
07-30-2000, 06:19 PM
I meant "containing two fields."

Cicely DeMars
07-30-2000, 06:34 PM
I thought about doing the case or the multiple field table, I was hoping to aviod them, but that's what I will try next. Thank you for the help!!