SQLite Forum

Convert datetime string to second since Epoch with millisecond precision
Login
I've recently discovered that this doesn't work with timezone suffixes,  
using format `YYYY-MM-DDThh:mm:ssZ[+/-]hh:mm`. I'm getting back nulls.

Can SQLite deal with the (optional) TZ offset suffixes? Thanks, --DD

```
C:\Users\ddevienne>sqlite3
SQLite version 3.28.0 2019-04-16 19:49:53
Enter ".help" for usage hints.
Connected to a transient in-memory database.
Use ".open FILENAME" to reopen on a persistent database.
sqlite> .null NULL
sqlite> select (julianday('2014-09-09T15:33:25Z+01:00') - 2440587.5) * 86400.0,
   ...>        (julianday('2014-09-09T15:33:25Z+1') - 2440587.5) * 86400.0,
   ...>        (julianday('2014-09-09T15:33:25Z01:00') - 2440587.5) * 86400.0,
   ...>        (julianday('2014-09-09T15:33:25Z-01:00') - 2440587.5) * 86400.0;
NULL|NULL|NULL|NULL
```