Return the values
getValues(tjsonb) → jsonbset
SELECT getValues(tjsonb
'[{"vehicleId": 1, "location": "Point(1 1)"}@2001-01-01,
{"vehicleId": 1, "location": "Point(1 1)"}@2001-01-02]');
-- {{"location": "Point(1 1)", "vehicleId": 1}}
Return the value at a timestamp
valueAtTimestamp(tjsonb,timestamptz) → jsonb
SELECT valueAtTimestamp(tjsonb
'[{"vehicleId": 1, "location": "Point(1 1)"}@2001-01-01,
{"vehicleId": 1, "location": "Point(2 2)"}@2001-01-02]', '2001-01-02');
-- {"location": "Point(2 2)", "vehicleId": 1}