Hi, i'm trying to write an expression that selects a specific max row and need help.
The app is for keeping track of mileage and I have tables of Vehicles, Locations, and trips.
I'm trying to streamline the form for users and I want the trips[Origin] for the trips to initially fill with the last trips[Destination] for that vehicle.
so far I have something like this for the initial value formula for trips[origin]
ANY(Select(
Locations[Location ID],
[Location ID]=
ANY(Select(trips[Destination],
AND(
[Date/Time]=MAX(Trips[Date/Time]),
[Vehicle]=[_THISROW].[Vehicle])
))
))
I'm getting thrown off though because if it's AND() then that vehicle needs to also have been the last one entered and it sometimes wont be. Any ideas where I'm going wrong?
Solved! Go to Solution.
Found the proper expression
Lookup(MAX(
Select(
trips[_RowNumber],[Vehicle]=[_THISROW].[Vehicle]
)
),trips,"_RowNumber","Destination")
Found the proper expression
Lookup(MAX(
Select(
trips[_RowNumber],[Vehicle]=[_THISROW].[Vehicle]
)
),trips,"_RowNumber","Destination")
User | Count |
---|---|
16 | |
7 | |
6 | |
3 | |
2 |