Nested If in pivot table

Purplethunder

New Member
Joined
Feb 8, 2019
Messages
2
Hi Guys,

Just found this forum so hoping you can help!

I have a pivot table with the following nested IF statement in the calculated field section but it only appears to be picking up the >20% part and the *8% bit at the end...any ideas why?

Thanks

Bonus=IF('% Margin'<0,0,IF('% Margin'>20%,'Margin Amount'*25%,IF('% Margin'>19%<20%,'Margin Amount'*20%,IF('% Margin'>18%<19%,'Margin Amount'*15%,IF('% Margin'>17%<18%,'Margin Amount'*10%,'Margin Amount'*8%))))):confused:

<tbody>
</tbody>

:confused::confused::confused:
 

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off

sandy666

Banned - Rules violations
Joined
Oct 24, 2015
Messages
7,499
'% Margin'>17%<18%

i think here should be AND('% Margin'>17%,'% Margin'<18%)
where '% Margin' can be 17,2% or 17,8%, ... etc

but maybe i m wrong ;)
 
Last edited:

Purplethunder

New Member
Joined
Feb 8, 2019
Messages
2
Thanks, our IT man figured it out in the end as below:

IFS('% Margin'>20%,'Margin Amount'*25%,'% Margin'>19%,'Margin Amount'*20%,'% Margin'>18%,'Margin Amount'*15%,'% Margin'>17%,'Margin Amount'*10%,'% Margin'>0,Margin Amount'*8%,'% Margin<=0,0)

<tbody>
</tbody>
 

Watch MrExcel Video

Forum statistics

Threads
1,129,590
Messages
5,637,285
Members
416,963
Latest member
samfuge

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top