In an sqlite3 database, I am storing date and time as unix timestamps. Examples of unix timestamp we can find on our database: 1457600307000, 1457600109000, 1457599991000.
When executing the following query:
SELECT datetime(my_date, 'unixepoch') as last_update
FROM my_table;
the results are not what we expect. the date we are getting from executing that query is: -1413-03-01 13:07:12
when we would actually expect a date and time from March / April 2016.
Is there anyway I can sqlite3 to read the timestamps correctly?