Hi guys,
can you help with formula? Below is a list of Customer transactions & their values within Industries. Formula should Sum Up Prices in Industries for each Cust ID and return name of Max Sum Industry into Leading Industry.
[TABLE="class: grid, width: 100"]
<tbody>[TR]
[TD]Cust ID[/TD]
[TD]Industry[/TD]
[TD]Price[/TD]
[TD]Leading Industry[/TD]
[/TR]
[TR]
[TD]5[/TD]
[TD]Restaurants[/TD]
[TD]100[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Airlines[/TD]
[TD]2300[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]Airlines[/TD]
[TD]3230[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]5[/TD]
[TD]Lodging[/TD]
[TD]800[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]Telco[/TD]
[TD]50[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Telco[/TD]
[TD]120[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]5[/TD]
[TD]Restaurants[/TD]
[TD]750[/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
Thus for Cust ID 5 rows this should be Restaurants, for Cust ID 1 Airlines etc... If there are more Leading Industries with same values, return any of the leading one.
Thanks much for help. BR, Gamca
can you help with formula? Below is a list of Customer transactions & their values within Industries. Formula should Sum Up Prices in Industries for each Cust ID and return name of Max Sum Industry into Leading Industry.
[TABLE="class: grid, width: 100"]
<tbody>[TR]
[TD]Cust ID[/TD]
[TD]Industry[/TD]
[TD]Price[/TD]
[TD]Leading Industry[/TD]
[/TR]
[TR]
[TD]5[/TD]
[TD]Restaurants[/TD]
[TD]100[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Airlines[/TD]
[TD]2300[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]Airlines[/TD]
[TD]3230[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]5[/TD]
[TD]Lodging[/TD]
[TD]800[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]Telco[/TD]
[TD]50[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Telco[/TD]
[TD]120[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]5[/TD]
[TD]Restaurants[/TD]
[TD]750[/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
Thus for Cust ID 5 rows this should be Restaurants, for Cust ID 1 Airlines etc... If there are more Leading Industries with same values, return any of the leading one.
Thanks much for help. BR, Gamca
Last edited: