Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-25243

Timezone support in date-time aggregation functions

    • Type: Icon: New Feature New Feature
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 3.3.10
    • Component/s: Aggregation Framework
    • Labels:
      None

      I have an app which needs to query DB for aggregate reports based on timezone. Currently we have to store dates in multiple timezones in order to make it possible to aggregate the data in the timezone expected. It would be great if date-time functions can calculate values based on timezone requested, like this:

      { $year: ["$date", "Europe/Moscow"]}

      or {$year: {$tz: ["$date", "Europe/Moscow"]}}

            Assignee:
            Unassigned Unassigned
            Reporter:
            roman.kisilenko Roman Kisilenko
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: