Mendix Date Filter Issue – Solution
The XPath token [%BeginOfCurrentDay%]
is resolved in UTC, not local time.
Your app works locally (AU timezone) because local runtime matches your timezone.
On the licensed node, server runs in UTC, causing date filter mismatches.
User timezone must be set to “Client” or specific AU timezone in Security → User Roles.
Mendix stores all DateTime
attributes in UTC; display format has no impact on logic.
Avoid using date as string (e.g., “14/06/2025”) in logic—only format for UI display.
XPath filters like [date <= '[%BeginOfCurrentDay%]']
fail in non-local timezones due to offset.
Instead of relying on XPath tokens, create start and end of day values in a microflow adjusted for AU time.
Use expressions like:
parseDateTimeUTC(formatDateTime([%CurrentDateTime%], 'yyyy-MM-dd') + ' 00:00:00', 'yyyy-MM-dd HH:mm:ss')
then adjust with addHours()
for timezone offset (e.g., +10 for AU).
Pass those values ($StartOfDayAU
, $EndOfDayAU
) into a DataGrid via microflow or datasource and use them in constraints.
Avoid relying on default tokens like [%BeginOfCurrentDay%]
in timezone-sensitive apps.
Problem is not in display formatting but in server-side evaluation of date filters using UTC.