On 14/8/19 8:47 PM, Richard Hipp wrote: > On 8/14/19, Adrian Ho <[email protected]> wrote: >> Here's a Dirty Little Secret: All the SQLite date functions are centered >> around strftime(), which is not implemented in a strictly correct sense >> in *every* Unix-like platform I've seen. > Not true. > > SQLite implements its own date and time computations, based on > algorithms taken from Astronomical Algorithms, 2nd Edition, 1998, > ISBN 0-943396-61-1. See https://sqlite.org/src/file/src/date.c for the > latest source code. > > An obscure exception is if you compile with > -DSQLITE_OMIT_DATETIME_FUNCS. In that case SQLite does invoke the > system strftime() routine as a fallback implementation for the > keywords CURRENT_TIME, CURRENT_DATE, and CURRENT_TIMESTAMP. But this > only happens when you use the obscure -DSQLITE_OMIT_DATETIME_FUNCS > compile-time option. I am aware of nobody who actually does that. Apologies, I did indeed missing the #ifdef SQLITE_OMIT_DATETIME_FUNCS around the currentTimeFunc() definition.
-- Best Regards, Adrian _______________________________________________ sqlite-users mailing list [email protected] http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

