4 ms·
They probably should have just omitted date/time functionality completely, keeping in spirit the "Lite" in SQLite. Their implementation is so bare bones as to
by SJC_Hacker 1y ago
They probably should have just omitted date/time functionality completely, keeping in spirit the "Lite" in SQLite. Their implementation is so bare bones as to be nearly useless compared to say PostgreSQL.
Users could then just use either client or user created functions to do the conversion, in whatever makes sense for the app. If all you need is GMT, just store seconds/milliseconds etc. from epoch. If you want to store older dates like in a historical database, strings or day/month/year split or even just single integer. Name columns appropriately to avoid ambiguity, like "gmt_ms" and it shouldn't cause too many problems.
- dardeaup 1y agoI disagree. I think that date/time data is pervasive enough to even warrant having built-in column data types for them. It's helpful when you care about data integrity.
- aldonius 1y agoThere's just enough there to be able to do "+1 month" calculations and similar, which is really helpful for generating dates in a range.