From: Amin on
Kindly explain to us what this expression actually means.
i got it from the sample database 2007 temlate

Qty To Reorder: IIf([Qty Below Target Level]>0,IIf([Qty Below Target
Level]<[Minimum ReOrder Quantity],[Minimum Reorder Quantity],[Qty Below
Target Level]),0)
From: John Spencer on
The expression is designed to return one of three values.

Qty To Reorder:
IIf([Qty Below Target Level]>0
,IIf([Qty Below Target Level]<[Minimum ReOrder Quantity]
,[Minimum Reorder Quantity],[Qty Below Target Level])
,0)

If the value of [Qty Below Target Level] is zero (or Less) then return zero
If the value of [Qty Below Target Level] greater than zero then return the
greater of [Minimum ReOrder Quantity] or [Qty Below Target Level]

Nested IIF clauses can be difficult to understand.

John Spencer
Access MVP 2002-2005, 2007-2010
The Hilltop Institute
University of Maryland Baltimore County

Amin wrote:
> Kindly explain to us what this expression actually means.
> i got it from the sample database 2007 temlate
>
> Qty To Reorder: IIf([Qty Below Target Level]>0,IIf([Qty Below Target
> Level]<[Minimum ReOrder Quantity],[Minimum Reorder Quantity],[Qty Below
> Target Level]),0)
 | 
Pages: 1
Prev: Add Fields from Record
Next: Two records one row