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

LIMIT Pushdown :Analytics query returns incorrect result if offset is a -ve value and limit is not pushed

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • 6.0.0
    • 6.0.0
    • analytics
    • Enterprise Edition 6.0.0 build 1347
    • Untriaged
    • Centos 64-bit
    • No
    • CX Sprint 113

    Description

      I have below documents ingested in CBAS from KV.

      id-0{"name":"dave","gender":"Male","salary":50,"married":false,"age":19,"employed":""}
      id-1{"name":"evan","gender":"Female","salary":100.15,"married":true,"age":25}
      id-2{"name":"john","gender":"Male","salary":150.55,"married":null,"age":44}
      id-3{"name":"sara","gender":"Female","salary":200.34,"married":false,"age":20}
      id-4{"name":"tom","gender":"Male","salary":250.99,"married":true,"age":31}
      

      Below N1QL query returns 2 records and treats -ve offset value as 0

      select * from default limit 2 offset -4
      

      The same query on Analytics workbench returns 0 records and LIMIT is not pushed to data-scan

      Note: The dataset name and KV bucket name is default in my case. offset with value -1 returns same result as in N1QL. Anything below that returns no result.

      Attachments

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

        Activity

          People

            tanzeem.ahmed Tanzeem Ahmed (Inactive)
            tanzeem.ahmed Tanzeem Ahmed (Inactive)
            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