Solr
  1. Solr
  2. SOLR-1871

Function Query "map" variant that allows "target" to be an arbitrary ValueSource

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.4
    • Fix Version/s: 4.7, 5.0
    • Component/s: search
    • Labels:
      None

      Description

      Currently, as documented at http://wiki.apache.org/solr/FunctionQuery#map, the "target" of a map must be a floating point constant. I propose that you should have at least the option of doing a map where the target is an arbitrary ValueSource.

      The particular use case that inspired this is that I want to be able to control how missing date fields affected boosting. In particular, I want to be able to use something like this in my function queries:

      map(mydatefield,0,0,ms(NOW))
      

      But this might have other uses.

      I'll attach an initial implementation.

      1. SOLR-1871.patch
        6 kB
        Chris Harris
      2. SOLR-1871.patch
        6 kB
        Chris Harris
      3. SOLR-1871.patch
        7 kB
        Shalin Shekhar Mangar
      4. SOLR-1871.patch
        8 kB
        Shalin Shekhar Mangar
      5. ASF.LICENSE.NOT.GRANTED--SOLR-1871.patch
        5 kB
        Chris Harris

        Activity

          People

          • Assignee:
            Shalin Shekhar Mangar
            Reporter:
            Chris Harris
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development