IIF query problems

gumbi17

Registered User.
Local time
Today, 02:32
Joined
Aug 23, 2011
Messages
43
Hey guys I am having problems trying to get my IIF to work! I have been working it awhile now and I think I am truely over thinking it! I first tried:

Expr4: IIf([State]="La","Parish","County")

I want the county text box to show county if it is any other state besides La, and if it has La then have it marked as Parish in the same text box. A friend of mine sent me a CO-PA line but I have never used it before:

CO-PA: IIf([Lease Counties]![STATE]="LA"," PARISH, "," COUNTY, ")


SQL:
IIf([Lease Counties]![STATE]="LA"," PARISH, "," COUNTY, ") AS [CO-PA]

IIf([State]="La","Parish","County") AS Expr4

What am I missing???
 
What you posted first should work just fine if the field name is really State and the value in the state is just the two letters LA.

Expr4:IIf([State]="La","Parish","County")

Although I would rename the Expr4 to something else

PaCo:IIf([State]="La","Parish","County")
 
Do you know what CO-PA that my friend first suggested meant? Is it a term with sql or with another system?
 

Users who are viewing this thread

Back
Top Bottom