dannycabrera
New Member
- Joined
- Apr 6, 2018
- Messages
- 5
I am looking to get the 2nd Largest Value with Criteria Avoiding Duplicates,
essentially I want to find out every customer in my records their min, max and 2nd to max ship date
This was my original take on it, '={LARGE(IF([Column2]=[@Column2],IF([Ship Date]<[@MAX],[Ship Date]),[@MAX]),2)}
[TABLE="width: 500"]
<tbody>[TR]
[TD]SHIP DATE
[/TD]
[TD]CUSTOMER
[/TD]
[TD]MIN
[/TD]
[TD]MAX
[/TD]
[TD]2ND MAX
[/TD]
[/TR]
[TR]
[TD]1/1/2013
[/TD]
[TD]ABC
[/TD]
[TD]1/1/2013
[/TD]
[TD]1/3/2013
[/TD]
[TD]1/2/2013
[/TD]
[/TR]
[TR]
[TD]1/2/2013
[/TD]
[TD]ABC
[/TD]
[TD]1/1/2013
[/TD]
[TD]1/3/2013
[/TD]
[TD]1/2/2013
[/TD]
[/TR]
[TR]
[TD]1/2/2013
[/TD]
[TD]ABC
[/TD]
[TD]1/1/2013
[/TD]
[TD]1/3/2013
[/TD]
[TD]1/2/2013
[/TD]
[/TR]
[TR]
[TD]1/3/2013
[/TD]
[TD]ABC
[/TD]
[TD]1/1/2013
[/TD]
[TD]1/3/2013
[/TD]
[TD]1/2/2013
[/TD]
[/TR]
[TR]
[TD]1/3/2013
[/TD]
[TD]ABC
[/TD]
[TD]1/1/2013
[/TD]
[TD]1/3/2013
[/TD]
[TD]1/2/2013
[/TD]
[/TR]
[TR]
[TD]1/2/2013
[/TD]
[TD]DEF
[/TD]
[TD]1/2/2013
[/TD]
[TD]1/5/2013
[/TD]
[TD]1/4/2013
[/TD]
[/TR]
[TR]
[TD]1/2/2013
[/TD]
[TD]DEF
[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]1/4/2013
[/TD]
[TD]DEF
[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]1/4/2013
[/TD]
[TD]DEF
[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]1/5/2013
[/TD]
[TD]DEF
[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]1/5/2013
[/TD]
[TD]DEF
[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
Thank you so much!
essentially I want to find out every customer in my records their min, max and 2nd to max ship date
This was my original take on it, '={LARGE(IF([Column2]=[@Column2],IF([Ship Date]<[@MAX],[Ship Date]),[@MAX]),2)}
[TABLE="width: 500"]
<tbody>[TR]
[TD]SHIP DATE
[/TD]
[TD]CUSTOMER
[/TD]
[TD]MIN
[/TD]
[TD]MAX
[/TD]
[TD]2ND MAX
[/TD]
[/TR]
[TR]
[TD]1/1/2013
[/TD]
[TD]ABC
[/TD]
[TD]1/1/2013
[/TD]
[TD]1/3/2013
[/TD]
[TD]1/2/2013
[/TD]
[/TR]
[TR]
[TD]1/2/2013
[/TD]
[TD]ABC
[/TD]
[TD]1/1/2013
[/TD]
[TD]1/3/2013
[/TD]
[TD]1/2/2013
[/TD]
[/TR]
[TR]
[TD]1/2/2013
[/TD]
[TD]ABC
[/TD]
[TD]1/1/2013
[/TD]
[TD]1/3/2013
[/TD]
[TD]1/2/2013
[/TD]
[/TR]
[TR]
[TD]1/3/2013
[/TD]
[TD]ABC
[/TD]
[TD]1/1/2013
[/TD]
[TD]1/3/2013
[/TD]
[TD]1/2/2013
[/TD]
[/TR]
[TR]
[TD]1/3/2013
[/TD]
[TD]ABC
[/TD]
[TD]1/1/2013
[/TD]
[TD]1/3/2013
[/TD]
[TD]1/2/2013
[/TD]
[/TR]
[TR]
[TD]1/2/2013
[/TD]
[TD]DEF
[/TD]
[TD]1/2/2013
[/TD]
[TD]1/5/2013
[/TD]
[TD]1/4/2013
[/TD]
[/TR]
[TR]
[TD]1/2/2013
[/TD]
[TD]DEF
[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]1/4/2013
[/TD]
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