Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-28964

DATE_RANGE_STR doesn't retrieve data across date formats.

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 5.5.0
    • 6.5.0
    • analytics
    • Enterprise Edition 5.5.0 build 2325
    • Untriaged
    • Unknown
    • CX Sprint 139, CX Sprint 140, CX Sprint 141

    Description

      Query:

      SELECT DATE_RANGE_STR('2006-01-02T15:04:05.999', '2016-01-02T15:04:05.999-08:00', 'quarter') AS Quarters;
      

      This query doesn't give any results in CBAS which N1QL returns results following the first date format in DATE_RANGE_STR function.

      N1QL output:

      [
        {
          "Quarters": [
            "2006-01-02T15:04:05.999",
            "2006-04-02T15:04:05.999",
            "2006-07-02T15:04:05.999",
            "2006-10-02T15:04:05.999",
            "2007-01-02T15:04:05.999",
            "2007-04-02T15:04:05.999",
            "2007-07-02T15:04:05.999",
            "2007-10-02T15:04:05.999",
            "2008-01-02T15:04:05.999",
            "2008-04-02T15:04:05.999",
            "2008-07-02T15:04:05.999",
            "2008-10-02T15:04:05.999",
            "2009-01-02T15:04:05.999",
            "2009-04-02T15:04:05.999",
            "2009-07-02T15:04:05.999",
            "2009-10-02T15:04:05.999",
            "2010-01-02T15:04:05.999",
            "2010-04-02T15:04:05.999",
            "2010-07-02T15:04:05.999",
            "2010-10-02T15:04:05.999",
            "2011-01-02T15:04:05.999",
            "2011-04-02T15:04:05.999",
            "2011-07-02T15:04:05.999",
            "2011-10-02T15:04:05.999",
            "2012-01-02T15:04:05.999",
            "2012-04-02T15:04:05.999",
            "2012-07-02T15:04:05.999",
            "2012-10-02T15:04:05.999",
            "2013-01-02T15:04:05.999",
            "2013-04-02T15:04:05.999",
            "2013-07-02T15:04:05.999",
            "2013-10-02T15:04:05.999",
            "2014-01-02T15:04:05.999",
            "2014-04-02T15:04:05.999",
            "2014-07-02T15:04:05.999",
            "2014-10-02T15:04:05.999",
            "2015-01-02T15:04:05.999",
            "2015-04-02T15:04:05.999",
            "2015-07-02T15:04:05.999",
            "2015-10-02T15:04:05.999"
          ]
        }
      ]
      

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          Re-triage issues for the next release.

          till Till Westmann added a comment - Re-triage issues for the next release.

          Build couchbase-server-6.5.0-2471 contains cbas-core commit bceed1e with commit message:
          MB-28964: Handle timezones in dateTime range function.

          build-team Couchbase Build Team added a comment - Build couchbase-server-6.5.0-2471 contains cbas-core commit bceed1e with commit message: MB-28964 : Handle timezones in dateTime range function.

          Now getting the result on MH build 3515:

          [
            {
              "Quarters": [
                "2006-01-02T15:04:05.999",
                "2006-04-02T15:04:05.999",
                "2006-07-02T15:04:05.999",
                "2006-10-02T15:04:05.999",
                "2007-01-02T15:04:05.999",
                "2007-04-02T15:04:05.999",
                "2007-07-02T15:04:05.999",
                "2007-10-02T15:04:05.999",
                "2008-01-02T15:04:05.999",
                "2008-04-02T15:04:05.999",
                "2008-07-02T15:04:05.999",
                "2008-10-02T15:04:05.999",
                "2009-01-02T15:04:05.999",
                "2009-04-02T15:04:05.999",
                "2009-07-02T15:04:05.999",
                "2009-10-02T15:04:05.999",
                "2010-01-02T15:04:05.999",
                "2010-04-02T15:04:05.999",
                "2010-07-02T15:04:05.999",
                "2010-10-02T15:04:05.999",
                "2011-01-02T15:04:05.999",
                "2011-04-02T15:04:05.999",
                "2011-07-02T15:04:05.999",
                "2011-10-02T15:04:05.999",
                "2012-01-02T15:04:05.999",
                "2012-04-02T15:04:05.999",
                "2012-07-02T15:04:05.999",
                "2012-10-02T15:04:05.999",
                "2013-01-02T15:04:05.999",
                "2013-04-02T15:04:05.999",
                "2013-07-02T15:04:05.999",
                "2013-10-02T15:04:05.999",
                "2014-01-02T15:04:05.999",
                "2014-04-02T15:04:05.999",
                "2014-07-02T15:04:05.999",
                "2014-10-02T15:04:05.999",
                "2015-01-02T15:04:05.999",
                "2015-04-02T15:04:05.999",
                "2015-07-02T15:04:05.999",
                "2015-10-02T15:04:05.999",
                "2016-01-02T15:04:05.999"
              ]
            }
          ]
          

          ritesh.agarwal Ritesh Agarwal added a comment - Now getting the result on MH build 3515: [ { "Quarters": [ "2006-01-02T15:04:05.999", "2006-04-02T15:04:05.999", "2006-07-02T15:04:05.999", "2006-10-02T15:04:05.999", "2007-01-02T15:04:05.999", "2007-04-02T15:04:05.999", "2007-07-02T15:04:05.999", "2007-10-02T15:04:05.999", "2008-01-02T15:04:05.999", "2008-04-02T15:04:05.999", "2008-07-02T15:04:05.999", "2008-10-02T15:04:05.999", "2009-01-02T15:04:05.999", "2009-04-02T15:04:05.999", "2009-07-02T15:04:05.999", "2009-10-02T15:04:05.999", "2010-01-02T15:04:05.999", "2010-04-02T15:04:05.999", "2010-07-02T15:04:05.999", "2010-10-02T15:04:05.999", "2011-01-02T15:04:05.999", "2011-04-02T15:04:05.999", "2011-07-02T15:04:05.999", "2011-10-02T15:04:05.999", "2012-01-02T15:04:05.999", "2012-04-02T15:04:05.999", "2012-07-02T15:04:05.999", "2012-10-02T15:04:05.999", "2013-01-02T15:04:05.999", "2013-04-02T15:04:05.999", "2013-07-02T15:04:05.999", "2013-10-02T15:04:05.999", "2014-01-02T15:04:05.999", "2014-04-02T15:04:05.999", "2014-07-02T15:04:05.999", "2014-10-02T15:04:05.999", "2015-01-02T15:04:05.999", "2015-04-02T15:04:05.999", "2015-07-02T15:04:05.999", "2015-10-02T15:04:05.999", "2016-01-02T15:04:05.999" ] } ]

          Build couchbase-server-6.6.2-9599 contains cbas-core commit bceed1e with commit message:
          MB-28964: Handle timezones in dateTime range function.

          build-team Couchbase Build Team added a comment - Build couchbase-server-6.6.2-9599 contains cbas-core commit bceed1e with commit message: MB-28964 : Handle timezones in dateTime range function.

          People

            sandeep.gupta Sandeep Gupta (Inactive)
            ritesh.agarwal Ritesh Agarwal
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty