You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since SQLite does not support a native date format, we use ISO encoded strings to save timestamps in the following format:
2024-03-17T14:00:01.053+01:00[Europe/Berlin]
This has multiple drawbacks:
since the datatime() function of SQLite only understands 2024-03-17T14:00:01.053+01:00 but not the [TZone] suffix, we have to manually strip this suffix away on every query before feeding the ISO-string into datetime().
Database queries that compare timestamps first need to convert these strings back to datetime using datetime which costs a lot of time. If we shadow the string encoded timestamps with epoch seconds and use these internally for comparisons, we can save a lot of computation.
The text was updated successfully, but these errors were encountered:
Since SQLite does not support a native date format, we use ISO encoded strings to save timestamps in the following format:
This has multiple drawbacks:
since the
datatime()
function of SQLite only understands2024-03-17T14:00:01.053+01:00
but not the[TZone]
suffix, we have to manually strip this suffix away on every query before feeding the ISO-string intodatetime()
.Database queries that compare timestamps first need to convert these strings back to datetime using
datetime
which costs a lot of time. If we shadow the string encoded timestamps with epoch seconds and use these internally for comparisons, we can save a lot of computation.The text was updated successfully, but these errors were encountered: