Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

iif inside an iif statement??? 1

Status
Not open for further replies.

kingz2000

Programmer
May 28, 2002
304
DE
Hi Guys,
Is it possible to have an iif inside an iif as far as formulas are concerned??
For example I have a formula :

=iif([service_anz_stops]=0;"";round((1-[service_op]/[service_anz_stops])*100;2) & '%')

but sometimes the outcome is negative, in which case it should just give 0.How do I do that?
Thanks in advance
 
=iif([service_anz_stops]=0,"",
iif([service_op]>=[service_anz_stops], 0,round((1-[service_op]/[service_anz_stops])*100,2) & '%'))

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top