none
Rank becoming 0 when sorting with custom attribute RRS feed

  • Question

  • Hi,

          I am facing a challenge, where when we are trying to sort the resutls using cutsom attribute the rank of the contents are coming as '0'. Please let me know is there any alternate for overcome this issue.

    Thanks,

    Kesava

     

    Monday, May 2, 2011 12:46 PM

Answers

  • Hi Kesava,

    I can provoke this behavior several ways:

    1) I sort on a field that is fullsort="yes" in the index-profile.  These will always show 0 in the rank.

    2) I sort on a field that is sort="yes"  and that is "empty", e.g. I have a field called custom3, which is not set.  Then I get rank="0" for all results.

    What is the field you are ranking on (index-profile), how are you sorting (sortby=?), and have you validated that you have values in that field?

    -Bjorn

    Friday, May 6, 2011 4:10 AM

All replies

  • Hi Kesava,

    I can provoke this behavior several ways:

    1) I sort on a field that is fullsort="yes" in the index-profile.  These will always show 0 in the rank.

    2) I sort on a field that is sort="yes"  and that is "empty", e.g. I have a field called custom3, which is not set.  Then I get rank="0" for all results.

    What is the field you are ranking on (index-profile), how are you sorting (sortby=?), and have you validated that you have values in that field?

    -Bjorn

    Friday, May 6, 2011 4:10 AM
  • Hi Bjorn,

         Below is the rank profile snippet we are using. My doubt here is, by default fast will sort the results based on ranks. If i want to sort results based on title then i am seeing the ranks as '0' for the results. So please let me know if there is a way we can get ranks as non zero when used custom attribute sorting.

    <rank-profile name="advportalrankprofile" rank-model="default" default="no"
                    stop-word-threshold="2E6"
                    position-stop-word-threshold="2E7">
        <authority weight="0" />
        <freshness weight="0" auto="yes" />
        <composite-rank composite-field-ref="advportalcontent">
                                    <proximity weight="150" />
                                    <context weight="150">
                                    <field-weight field-ref="title" value="400"/>
                                    <field-weight field-ref="summary" value="150"/>
                                    <field-weight field-ref="body" value="100"/>
                                    <field-weight field-ref="category" value="65"/>
      <field-weight field-ref="subcategory" value="65"/>
      <field-weight field-ref="contact" value="50"/>
      <field-weight field-ref="contenttype" value="50"/>
      <field-weight field-ref="email" value="65"/>
      <!--<field-weight field-ref="filtercategory" value="65"/>-->
          </context>
        </composite-rank>
      </rank-profile>

    Thanks,

    Kesava

    Wednesday, July 13, 2011 4:50 PM
  • Hi Kesava,

     

    As Bjorn asked, what is the field you are ranking on (index-profile), how are you sorting (sortby=?)?  Are you doing sortby on advportalrankprofile, or the default rank profile?  You would need to perform a sortby on the advportalrankprofile rank profile.  If  you are already doing that, I would suggest trying your query at the qrserver, and appending "qtf_packfql:debug=1" to the end of the query string, and changing the xsearch to rsearch (example assuming default port range: http://nodename.com:15100/cgi-bin/rsearch...).  The XML output with rsearch will return information useful for relevancy tuning (ranklog), and the individual entries (HITs) in the XML will contain the RANK info.  Let us know your findings.

     

    Thanks!

    Rob Vazzana | Microsoft | Enterprise Search Group | Sr Support Escalation Engineer |  http://www.microsoft.com/enterprisesearch 


    Wednesday, July 27, 2011 8:08 PM
    Moderator