hawkfish / olapscript

An OLAP engine for Google App Script
MIT License
3 stars 1 forks source link

Add real SQL Date Class #96

Closed hawkfish closed 2 years ago

hawkfish commented 2 years ago

JavaScript's Date class is more like a badly implemented version of SQL's TIMESTAMP WITH TIME ZONE class. To handle date-precision data, you really need a separate class, preferably one that counts days since an epoch. As a first pass, it might make sense to wrap Date and constrain it's construction to midnight UTC...