MIFS with complex COUNTIF formula inside

Leticia

New Member
Joined
Jun 9, 2021
Messages
45
Office Version
  1. 365
Platform
  1. Windows
Hi! I am trying to find the oldest date in KPI!$G:$G meeting all the conditions of either these two formulas (I obtained the same result)

- COUNTIFS(KPI!$P:$P;"PENDIENTE";KPI!$G:$G;"<="&$F$4)+COUNTIFS(KPI!$G:$G;"<="&$F$4;KPI!$Q:$Q;">"&$F$4)-IFERROR(IFS($G$4="YES";SUM(COUNTIFS(KPI!$R:$R;{"R.";"7250"};KPI!$G:$G;"<="&$F$4;KPI!$Q:$Q;">"&$F$4;KPI!$Q:$Q;"<"&$F$4+30)));0)
- IF($G$4="YES";COUNTIFS(KPI!$P:$P;"PENDIENTE";KPI!$G:$G;"<="&$F$4)+COUNTIFS(KPI!$G:$G;"<="&$F$4;KPI!$Q:$Q;">"&$F$4)-SUM(COUNTIFS(KPI!$R:$R;{"R.";"7250"};KPI!$G:$G;"<="&$F$4;KPI!$Q:$Q;">"&$F$4;KPI!$Q:$Q;"<"&$F$4+30));COUNTIFS(KPI!$P:$P;"PENDIENTE";KPI!$G:$G;"<="&$F$4)+COUNTIFS(KPI!$G:$G;"<="&$F$4;KPI!$Q:$Q;">"&$F$4))

Thank you!
 

Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"
minisheet pls.

Hi! I dont know why it does not let me extract the minisheet.
but here it would be simplified. THANK YOU!

=IF($G$4="YES";COUNTIFS('EV80'!$C:$C;"PENDIENTE";'EV80'!$B:$B;"<="&$F$4)+COUNTIFS('EV80'!$B:$B;"<="&$F$4;'EV80'!$D:$D;">"&$F$4)-SUM(COUNTIFS('EV80'!$E:$E;{"R.";"7250"};'EV80'!$B:$B;"<="&$F$4;'EV80'!$D:$D;">"&$F$4;'EV80'!$D:$D;"<"&$F$4+30));COUNTIFS('EV80'!$C:$C;"PENDIENTE";'EV80'!$B:$B;"<="&$F$4)+COUNTIFS('EV80'!$B:$B;"<="&$F$4;'EV80'!$D:$D;">"&$F$4))

1624524423174.png

1624524305181.png
 
Upvote 0
minisheet pls.
=IF($G$4="YES";MIN(MINIFS('EV80'!$G:$G;'EV80'!$P:$P;"PENDIENTE";'EV80'!$G:$G;"<="&$F$4);MINIFS('EV80'!$G:$G;'EV80'!$G:$G;"<="&$F$4;'EV80'!$Q:$Q;">"&$F$4);IF($G$4="YES";MINIFS('EV80'!$G:$G;'EV80'!$G:$G;"<="&$F$4;'EV80'!$Q:$Q;">"&$F$4;'EV80'!$Q:$Q;"<"&$F$4+30;'EV80'!$R:$R;"R.");"");IF($G$4="YES";MINIFS('EV80'!$G:$G;'EV80'!$G:$G;"<="&$F$4;'EV80'!$Q:$Q;">"&$F$4;'EV80'!$Q:$Q;"<"&$F$4+30;'EV80'!$R:$R;"7250");""));MIN(MINIFS('EV80'!$G:$G;'EV80'!$P:$P;"PENDIENTE";'EV80'!$G:$G;"<="&$F$4);MINIFS('EV80'!$G:$G;'EV80'!$G:$G;"<="&$F$4;'EV80'!$Q:$Q;">"&$F$4)))

Having obtained this formula, I want to exclude the minimum values obtained from
IF($G$4="YES";MINIFS('EV80'!$G:$G;'EV80'!$G:$G;"<="&$F$4;'EV80'!$Q:$Q;">"&$F$4;'EV80'!$Q:$Q;"<"&$F$4+30;'EV80'!$R:$R;"R.");"");IF($G$4="YES";MINIFS('EV80'!$G:$G;'EV80'!$G:$G;"<="&$F$4;'EV80'!$Q:$Q;">"&$F$4;'EV80'!$Q:$Q;"<"&$F$4+30;'EV80'!$R:$R;"7250");"")), instead of including them too
 
Upvote 0

Forum statistics

Threads
1,223,881
Messages
6,175,161
Members
452,615
Latest member
bogeys2birdies

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
Back
Top