Uploaded image for project: 'Teiid'
  1. Teiid
  2. TEIID-5376

Timezone handling discrepancies in MongoDB

    XMLWordPrintable

Details

    • Bug
    • Resolution: Won't Do
    • Major
    • None
    • None
    • Misc. Connectors
    • None

    Description

      Suppose this query against a MongoDB-backed VDB and you're running it in timezone UTC+1:

      SELECT timestampvalue, HOUR(timestampvalue) AS TheHour FROM BQT1.SmallA WHERE (HOUR(timestampvalue) = 16);
      

      If the database contains a timestamp '2000-01-01 16:00:00', you will get this row as result:

      timestampvalue TheHour
      2000-01-01 17:00:00 16

      Looks like this is because the timestampvalue column is fully evaluated by Teiid and converted into the user's timezone, but the hour() call is pushed and evaluated by MongoDB and therefore evaluated as UTC and is not converted by Teiid to user's timezone.

      Attachments

        Activity

          People

            rhn-engineering-shawkins Steven Hawkins
            jmartisk@redhat.com Jan Martiska
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: