Forum Discussion
ChristianDGreat
3 years agoResolver I
Complex Scoring
Hi everyone, I was thinking on solving this but I got stuck to the last part.
So imagine you have this kind of table
| Order Number | Order Number Line | Status | Date | Qty |
| AAA | AA1 | Booked | 2/2/23 9:29 AM | 2 |
| AAA | AA1 | Booked | 2/3/23 9:29 AM | 2 |
| AAA | AA1 | Shipped | 2/4/23 9:29 AM | 3 |
| AAA | AA1 | Shipped | 2/5/23 9:29 AM | 2 |
| AAA | AA2 | Booked | 2/6/23 9:29 AM | 4 |
| AAA | AA2 | Booked | 2/7/23 9:29 AM | 4 |
| AAA | AA2 | Shipped | 2/8/23 9:29 AM | 2 |
| AAA | AA2 | Shipped | 2/9/23 9:29 AM | 3 |
| AAA | AA3 | Shipped | 2/10/23 9:29 AM | 1 |
| AAA | AA3 | Shipped | 2/11/23 9:29 AM | 3 |
| BBB | BB1 | Booked | 2/12/23 9:29 AM | 2 |
| BBB | BB1 | Booked | 2/13/23 9:29 AM | 3 |
| BBB | BB1 | Booked | 2/14/23 9:29 AM | 5 |
| BBB | BB1 | Booked | 2/15/23 9:29 AM | 6 |
| BBB | BB1 | Shipped | 2/16/23 9:29 AM | 6 |
| BBB | BB2 | Booked | 2/17/23 9:29 AM | 3 |
| BBB | BB2 | Booked | 2/18/23 9:29 AM | 4 |
| BBB | BB2 | Shipped | 2/19/23 9:29 AM | 4 |
The goal is to have something like this
Basically I want to put that into a Matrix Table.
let me explain the Logic.
- First is we want to groupby Order Number and Order Line Number+
- Column D = is a sum(qty) of the Last Time(from Date Table) the Order Line Number is booked.
- Column F = is the sum(qty) of the first time(from the date table) the Order Line Number is shipped
- Column G is the score, the logic there is both value from Column D and Column F are equal it will be 1 point, otherwise its 0,
The tricky part is on the grand total. if you look at the one I circled, Order Number = AAA, you can see that the total is 6 for column D and 6 on column F, even Order Number AAA score is only 1, they will still get a score of 3(the reason its 3 its because of the number of unique order line number) on the total because they have the same number in the TOTAL level.
Let me know if this makes sense.
The score makes no sense as the quantity for AA2 is not the same (4 vs 2) so the top score should be 0.
See attached for the proposed implementation.
2 Replies
- lbendlinSuper User
The score makes no sense as the quantity for AA2 is not the same (4 vs 2) so the top score should be 0.
See attached for the proposed implementation.
- ChristianDGreatResolver I
Thanks for this but I figure it out.
Its using INSCOPE formula,
IF INSCOPE of the ORDER NUMBER compute with the Total, and if its in ORDER ITEM LINE it will compute by Order Item Line.Thanks!