Sunday, 11 June 2017

mongoose Find query with UTC time

I have a problem. i store my data in the database in GMT +2.

But i want to grab it from the database in GMT 0 or utc to support any offset in the future.
If i have     `"time" : ISODate("2017-06-11T10:39:57.000Z")`, But it's in GMT +2,
And i want to:

    _schema.find({time:{$gt:2017-06-11T09:00:00.000Z}) in GMT 0.



via edan

No comments:

Post a Comment