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

Enhance the map() function to take in a default value

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.3
    • Fix Version/s: 1.4
    • Component/s: None
    • Labels:
      None

      Description

      The map function currently takes in only one min,max target and returns the field's value if it is not between min and max. This makes it very difficult to use it for scoring.

      This issue aims to add an optional fifth parameter to the map function query which will be a default value that is used if the field's value does not fall between min and max. If this parameter is not specified, the behavior is the same as before for back-compatibility.

        Attachments

        1. SOLR-966.patch
          3 kB
          Shalin Shekhar Mangar
        2. SOLR-966.patch
          2 kB
          Noble Paul

          Activity

            People

            • Assignee:
              shalinmangar Shalin Shekhar Mangar
              Reporter:
              noble.paul Noble Paul
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: