Error on IIF (2 Viewers)

Adamfm

Registered User.
Local time
Today, 13:09
Joined
Jul 24, 2019
Messages
12
Hi Mark,

Yes I understand now, even though it was showing 1 and 0 they were text rather than numbers. I actually changed the table values from Yes/No to numbers which was the easiest thing for me.

Thanks for the advice!
 

Mark_

Longboard on the internet
Local time
Today, 06:09
Joined
Sep 12, 2017
Messages
2,111
Adamfm,

Are you actually looking for the percentage failed or the ratio or fail to success?

Percentage failed would be failed/success+failed. This means if you have 20 failed and 80 success, you'd have a total of 100 and your percentage would be 20%. Ratio would be 20 to 80 or 25%.
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 21:09
Joined
May 7, 2009
Messages
19,175
if you are using Grouped by query, use this as "Expression"
Code:
PercentageFail: Sum(IIf([successful]=0,1,0))/Sum(1)*100

PercentageSuccess: Sum(IIf([successful],1,0))/Sum(1)*100
 

Users who are viewing this thread

Top Bottom