Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-13560

Add isNull and notNull Stream Evaluators

    XMLWordPrintableJSON

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 8.2
    • Component/s: None
    • Labels:
      None

      Description

      This ticket adds two Stream Evaluators for testing for null values in Tuples. These are much needed functions as currently null values are not possible to detect with the eq Stream Evaluator because null values are evaluated to the parameter name, rather then null. This change was made to support String literal parameters without quotes.

      The isNull and notNull Stream Evaluators properly detect nulls so they can be used to filter tuples in a having expression or replace nulls in a select expression.

      Sample syntax for null filtering:

      having(random(testapp, q="*:*", fl="response_d", rows="20000"),
             notNull(response_d))

      Sample syntax for null filterring:

      select(random(testapp, q="*:*", fl="id, response_d", rows="20000"),
             id,
             if(isNull(response_d),-1, response_d) as response_d)

       

        Attachments

        1. SOLR-13560.patch
          12 kB
          Joel Bernstein

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              jbernste Joel Bernstein
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: