Need to nest a function in complex formula.

Execu2v

New Member
Joined
Dec 27, 2022
Messages
4
Office Version
  1. 365
Platform
  1. Windows
Thank you for looking in ...

I am creating four ranked customer lists, by segment, from a master sales analysis data set.

The desired lists show top, ranked sales variance for each segment, ABCD. ABCD segments are defined by two factors, 1) total sales and 2) sales variance.

In some cases, the wrong segment name results from the formula (below) because the variance amount ($812) is the same for unique customers in segments C and D. I assume it's using the first reference it sees.

My want is to nest a function -- an IFs or AND??? -- that assigns the right customer's name/#, per the variance ($812), using the assigned segment ID field from the data set. Assume the Segment ID exists in field AE.

How and where would I alter the formula below to query that the segment name must be "D" in addition to the ($812) Variance.

Big thanks to any/all who might post a solution!

=@IF(DT8="","",INDEX($AG$2:$AG$1541,AGGREGATE(15,6,(ROW($AD$2:$AD$1541)ROW($AD$2)+1)/($AD$2:$AD$1541=DU8),COUNTIF($DU$8:DU8,DU8))))
 

Excel Facts

What do {} around a formula in the formula bar mean?
{Formula} means the formula was entered using Ctrl+Shift+Enter signifying an old-style array formula.
can you post using XL2BB the cells you are working with and what your looking for as a solution
 
Upvote 0
hajiali, thank you for taking time to review. The data posting protocol was as daunting as the original problem, however searched Google and used =UNIQUE(FILTER($H$2:$H$3042,($DV$5=$AF$2:$AF$3042) * (DU8=$AE$2:$AE$3042))). It allowed me to use multiple criteria while also listing multiple entities that shared criteria. ... The new SPILL error was another hurdle to over come! Again, I appreciate your want to help others. Impressive.
 
Upvote 0

Forum statistics

Threads
1,223,886
Messages
6,175,196
Members
452,616
Latest member
intern444

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