How to match the product name with an expression value
I'm hoping someone can help me out with something I've been struggling on. I am trying to get the name in a text box of the product with the worst variance year to date against budget. I can get the variance using the formula below. This basically looks at each month in the year and if the current month is greater or equal to it, it sums it and then compares it against actuals. The aggr groups it by brand and then the min takes the smallest one. The formula returns -3.18 which is the largest variance of the brands but I need it to return the brand's name. I'm thinking the match() function could be of use here but I can't get it to work... any thoughts?