If I have a [TextField] and a [DateField]...
TextField can be "A", "B", "C", or "D".
In my query I have a calculated date field [CertDate] that I want to equal DateField if "A" or "B", and equal to today's date if not.
I've tried the following expressions with no luck:
CertDate: IIf([TextField]="A" Or [TextField]="B", [DateField], Date())
and this:
CertDate: IIf([TextField]="A",[DateField],IIf([TextField]="B",[DateField],[Date()))
Both work for "A", "C", and "D" but return today's date for "B".
What's the proper way to write the expression??
Thanks!!
Mike
TextField can be "A", "B", "C", or "D".
In my query I have a calculated date field [CertDate] that I want to equal DateField if "A" or "B", and equal to today's date if not.
I've tried the following expressions with no luck:
CertDate: IIf([TextField]="A" Or [TextField]="B", [DateField], Date())
and this:
CertDate: IIf([TextField]="A",[DateField],IIf([TextField]="B",[DateField],[Date()))
Both work for "A", "C", and "D" but return today's date for "B".
What's the proper way to write the expression??
Thanks!!
Mike