Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I am trying to sum the maximum value of a field, and not sure which function to use.
I can get the maximum value without any problems using Max or Maxstring, but when I go to sum those values I run into trouble.
In the example below I want to sum the yellow shaded odomoter readings to get a result of 171,747:
DATE | REGO | ODOMOTER |
11/07/2013 | 108RMK | 42436 |
20/07/2013 | 108RMK | 43004 |
29/07/2013 | 108RMK | 43572 |
7/08/2013 | 108RMK | 44140 |
26/07/2013 | 109RMK | 55334 |
1/08/2013 | 109RMK | 55895 |
7/08/2013 | 109RMK | 56456 |
18/07/2013 | 110RMK | 70081 |
26/07/2013 | 110RMK | 70616 |
3/08/2013 | 110RMK | 71151 |
Any help appreciated.
Thanks
Wayne
If I understand correctly, you could use something like the following expression:
=SUM(AGGR(MAX(ODOMOTER),REGO))
-Clark
Wayne
If I understand correctly, you could use something like the following expression:
=SUM(AGGR(MAX(ODOMOTER),REGO))
-Clark
You may use
=Sum(Aggr(FirstSortedValue(ODOMOTER,-DATE),REGO))
Thanks Clark,
That's what I was looking for.
Wayne