I have a problem with unix timestamps in sqlite.
I want to store the result of System.currentTimeMillis() in sqllite (integer). But when i read the stored value from the db, i always get a negativ value like -203027418, and not the value, i stored, like 1494445606119
Here is the scheme of my db:
// Database creation sql statement
private static final String CREATE_ROUTE = "create table "
+ TABLE_ROUTE + "("
+ ROUTE_COLUMN_ID + " integer primary key autoincrement, "
+ ROUTE_COLUMN_DATE + " integer);";
private static final String CREATE_LOCATION = " create table "
+ TABLE_LOCATION + "("
+ LOCATION_COLUMN_ID + " integer primary key autoincrement, "
+ LOCATION_COLUMN_ROUTEID + " integer, "
+ LOCATION_COLUMN_LAT + " real, "
+ LOCATION_COLUMN_LONG + " real, "
+ LOCATION_COLUMN_DATE + " integer, "
+ " FOREIGN KEY(" + LOCATION_COLUMN_ROUTEID + ") REFERENCES " + TABLE_ROUTE + "(" + ROUTE_COLUMN_ID + "));";`
Screenshots from debugging:
At storing, the value seems fine: value in object
but, when i read from db, i only get such values: value after reading from DB
Anyone know, whats happening here?

2017-01-23T12:34:56.789Z.