couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jens Alfke <j...@couchbase.com>
Subject Re: map timezones
Date Wed, 06 Mar 2013 07:45:38 GMT

On Mar 5, 2013, at 10:12 PM, Will Heger <will.heger@gmail.com> wrote:

> Eventually, I will need to do reporting and math on these values using
> local time.

What’s “local time”? The time zone of the server? A map/reduce function has to be a
“pure” function, so it can’t depend on any external inputs that might change, such as
the current timezone.

Time zone conversions should be done by the client (or an app server), not the database. 

(Besides which,  JavaScript date operations are seriously slow, and can hurt performance of
your CouchDB.)

—Jens
Mime
View raw message