What is wrong with this formula? Help!

  • Thread starter Thread starter Kaylen
  • Start date Start date
K

Kaylen

=IIf(DCount("*","UM Files","[13] IN ('Y','N')
AND [Review Date] =#" & [Enter Date] &
"#")=0,"N/A",FormatPercent((DCount("*","UM Files","[13] ='Y' and [Review
Date]=#" & [Enter Date] & "#")/DCount("*","UM Files","[13] IN ('Y','N') and
[Review Date=#" & [Enter Date] & "#")),0))

I put this formula in a query but I got an error message:

Missing ), ], or Item in query expression '[13] IN ('Y','N') and [Review
Date=#9/9/09#'.

then I got this error message:

This expression is typed incorrectly, or it is too complex to be evaluated.
For example, a numeric expression may contain too many complicated elements.
Try simplifying the expression by assigning parts of the expression to
variables. (Error 3071)
 
IMHO, parameter prompts have no place in quality applications.

You are missing a "]" after the final Review Date. There may be other issues.
 
Thank you so so much Duane. This is the correct master formula I need for my
project. Thank you for your help!

Duane Hookom said:
IMHO, parameter prompts have no place in quality applications.

You are missing a "]" after the final Review Date. There may be other issues.

--
Duane Hookom
Microsoft Access MVP


Kaylen said:
=IIf(DCount("*","UM Files","[13] IN ('Y','N')
AND [Review Date] =#" & [Enter Date] &
"#")=0,"N/A",FormatPercent((DCount("*","UM Files","[13] ='Y' and [Review
Date]=#" & [Enter Date] & "#")/DCount("*","UM Files","[13] IN ('Y','N') and
[Review Date=#" & [Enter Date] & "#")),0))

I put this formula in a query but I got an error message:

Missing ), ], or Item in query expression '[13] IN ('Y','N') and [Review
Date=#9/9/09#'.

then I got this error message:

This expression is typed incorrectly, or it is too complex to be evaluated.
For example, a numeric expression may contain too many complicated elements.
Try simplifying the expression by assigning parts of the expression to
variables. (Error 3071)
 
Back
Top