Hi everyone,
I’m working with Tasks in ArcGIS Field Maps and I’m trying to implement a shift-based time filter.
Goal / Requirement
We run operational shifts from 06:00 today to 06:00 the next day. We need the task list to be consistent across midnight, e.g.:
- A user logs in at 23:00 and sees the tasks for the current shift (06:00 → 06:00).
The same user logs in again at 02:00 (after midnight) and should still see the same shift tasks, not a new set.
The task layer contains the standard due date field esritask_duedate, which is filled and used as the “deadline”.
What works (but not sufficient)
A basic filter like the following is valid and works logically for “calendar day”, but it breaks after midnight because the day changes:
esritask_duedate BETWEEN (CURRENT_DATE + 0.2083333333) AND (CURRENT_DATE + 1.2083333333) (0.2083333333 = 5/24, intended to represent “06:00 local” depending on time zone setup.)
Problem: when the calendar day changes at midnight, users logging in between 00:00–06:00 see the next day’s window, and tasks from the ongoing shift are no longer included.
Attempted solution (dynamic switch “before/after 06:00”)
To keep the same shift across midnight, I tried a dynamic “switch” logic:
- If current time is before 06:00, filter yesterday 06:00 → today 06:00
Else filter today 06:00 → tomorrow 06:00
(
(CURRENT_TIMESTAMP < (CURRENT_DATE + 0.2083333333) AND esritask_duedate BETWEEN ((CURRENT_DATE - 1) + 0.2083333333) AND (CURRENT_DATE + 0.2083333333)) OR (CURRENT_TIMESTAMP >= (CURRENT_DATE + 0.2083333333) AND esritask_duedate BETWEEN (CURRENT_DATE + 0.2083333333) AND (CURRENT_DATE + 1.2083333333)))Issue
This expression appears valid in Field Maps Designer, but when opening the map in theField Maps mobile app, Tasks fail to load and the app shows:
“Tasks couldn’t be loaded. Contact the map author for more information.”
I also tested using EXTRACT(HOUR FROM CURRENT_TIMESTAMP) earlier, but Field Maps mobile did not support it either (same outcome).
Question
- Is there a Field Maps mobile limitation regarding dynamic SQL functions (CURRENT_TIMESTAMP, EXTRACT, etc.) in Tasks filters / to-do lists?
- Is there a recommended approach to implement a 06:00–06:00 shift window using only esritask_duedate that works reliably in Field Maps mobile?
- If this is not supported via SQL in Field Maps mobile, what is the best practice workaround?e.g., precomputing a shift anchor field (like shift_date) on insert/update (server-side or via automation), and filtering on that instead?
Any hints, confirmed limitations, or working examples would be greatly appreciated.
Thanks in advance!