Skip to main content
Participant
March 12, 2021
Question

Cfindex fieldboost does nothing - ColdFusion 2018

  • March 12, 2021
  • 1 reply
  • 321 views

The documentation does not list fieldBoost in the list of valid attributes to cfindex, yet further down the page its function is described (see https://helpx.adobe.com/coldfusion/cfml-reference/coldfusion-tags/tags-i/cfindex.html ). It does not seem to have any effect on the cfindex tag. Has fieldBoost been removed (and how can we then boost a particular field) or has the syntax changed (and to what)? This is a ColdFusion 2018 Standard Edition running on Win Server 2016. 

Best, Robert

    This topic has been closed for replies.

    1 reply

    BKBK
    Community Expert
    Community Expert
    March 12, 2021

    Are you using 

     

    <cfindex fieldBoost="title">

     

    or

     

    <cfindex fieldBoost="title:3"> ?

     

    The usual recommendation is to use the second, which includes a weighting factor (3).

    Participant
    March 12, 2021

    Thank you so much for your answer, I have indeed tried both, but it does not seem to have any effect on the results returned. For instance: first I index without any fieldboost, and a search for "tax" returns this document with "tax" in the title. Then I reindex with "fieldboost:100" and expect the score to be higher, but it is unchanged. Is there perhaps any range limit for the boost value?

    Participant
    March 12, 2021

    Correction: I re-index with fieldBoost="title:100"