Bad IIf

D

DS

This if statement in a Query always returns the first value.....any
help is appreciated.
Thanks
DS
N2: IIf([tblCheckDetails].[CDDiscountDP]>=1 And
[tblCheckDetails].[CDDiscountAction]<>"B"," " & "*" &
[tblDiscounts].[DiscountName],IIf([tblCheckDetails].[CDDiscountDP]>=1
And [CDDiscountAction]="A"," " & "**" & [tblDiscounts].[DiscountName]))
 
J

John W. Vinson

This if statement in a Query always returns the first value.....any
help is appreciated.
Thanks
DS
N2: IIf([tblCheckDetails].[CDDiscountDP]>=1 And
[tblCheckDetails].[CDDiscountAction]<>"B"," " & "*" &
[tblDiscounts].[DiscountName],IIf([tblCheckDetails].[CDDiscountDP]>=1
And [CDDiscountAction]="A"," " & "**" & [tblDiscounts].[DiscountName]))

Could you please describe in words what the query is intended to do? What is
the context - is this a calculated field in the query?


John W. Vinson [MVP]
 

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

Similar Threads

SQL Rowsource 1
DSum Wrong Argument 2
Not returning a value 7
OPEN ARGS Trouble 2
Blank in Listbox 1
Sub-Query Problem 8
Line Break 9
UNION Error 9

Top