none
FAST Search keywords (best bets) not showing up RRS feed

  • Question

  • Hello,

    I've encountered a very strange issue. I have a page with Core Search Results web part, Refinement Panel web part and Search Best Bets web part.

    When I perform a search for a keyword I added in the FAST Search Keywords section of my site collection - everything works great, but if I use the Append Text To Query option of the Core search result web part with any kind of query (for example contentsource<>something) the best bets web part no longer show any results, no matter what the keyword is. If I try to get the xml of the query in the best bets web part I get <All_Results />.

    Has anyone encountered anything like this before? I'm banging my head over this issue the entire day without even a glimpse of idea what’s wrong :(

    Thanks,

    Johnny.


    Best regards, Johnny Tordgeman.
    My Blog
    Sunday, November 20, 2011 5:33 PM

Answers

  • The BestBet web part (HighConfidenceWebPart) is sealed so you cannot inherit from it, while the VisualBestBetWebPart is open for inheritence.

    If you inherit or create your own I guess it won't make much difference. Fire up Reflector and see what the code looks like and you get the idea pretty quick on how it works.

    Regards,
    Mikael Svenson 


    Search Enthusiast - SharePoint MVP/WCF4/ASP.Net4
    http://techmikael.blogspot.com/
    Monday, November 21, 2011 10:43 AM

All replies

  • Hi,

    Best Bets / Visual Best Bets has to match 100% for them to show. When you add extra query terms with the "Append Text To Query" option, you are no longer matching it 100%, and that's why it won't show.

    You might want to take a look at my web part or the code in it at spsearchparts.codeplex.com. It works on substring matching as well, but the code might not be 100% production ready depending on what features you are using.

    Regards,
    Mikael Svenson 


    Search Enthusiast - SharePoint MVP/WCF4/ASP.Net4
    http://techmikael.blogspot.com/
    Sunday, November 20, 2011 9:25 PM
  • Hey Mikael,

    I've based my core search result web part expansion on the same article as well ;)

    I'll take a deeper look in your code to try and understand how to pass the query as is so the best bet will work.

    I'll report back tomorrow on my hopeful sucess... Thanks alot meanwhile :)

     


    Best regards, Johnny Tordgeman.
    My Blog
    Sunday, November 20, 2011 9:38 PM
  • Hey Mikael,

    I tested your web part and sadly it didnt help me :(

    What is happening is if i search for a word that is a keyword (for example, bank) it sets the enablefql property to false, and passing an empty FixedQuery to the server, which means that the keyword does appear but all my filtering is gone...

    Is there no way to have both the fql query AND the keyword to show up?

    Thanks!


    Best regards, Johnny Tordgeman.
    My Blog
    Monday, November 21, 2011 9:50 AM
  • Hi,

    If you use FQL, then keywords will not work at all. They only work with Keyword syntax.

    And I was a bit quick... I should add separate best bets/visual best bets web parts to support partial matching on keywords. Keywords only works with synonyms in the current web part.

    If you override the webpart, and set FixedQuery to a blank string, are you then getting zero results? FixedQuery will override the query string, Appendedquery will append to the original one. And I haven't tested if FixedQuery with the oob web part will trigger keywords or not.

    Regards,
    Mikael Svenson 


    Search Enthusiast - SharePoint MVP/WCF4/ASP.Net4
    http://techmikael.blogspot.com/
    Monday, November 21, 2011 10:14 AM
  • Hey,

    FixedQuery with oob web part doesnt trigger keywords... that was my main issue ;)

    My question is, what are my options here?

    Can i inherit and override the best bets web part?

    Should i build my own best bets web part from scratch?

    Thanks,

    Johnny.


    Best regards, Johnny Tordgeman.
    My Blog
    Monday, November 21, 2011 10:24 AM
  • The BestBet web part (HighConfidenceWebPart) is sealed so you cannot inherit from it, while the VisualBestBetWebPart is open for inheritence.

    If you inherit or create your own I guess it won't make much difference. Fire up Reflector and see what the code looks like and you get the idea pretty quick on how it works.

    Regards,
    Mikael Svenson 


    Search Enthusiast - SharePoint MVP/WCF4/ASP.Net4
    http://techmikael.blogspot.com/
    Monday, November 21, 2011 10:43 AM
  • Having experienced this same issue I came up with an interesting workaround.  I was using the IsDocument:true in the "append text to query" and missing my best bets due to the various issues described here.

    The solution was:

      • remove the IsDocument:true from the default Search Core Results "Append Text to Query" box
      • Add a second Search Core Results to the results page, add IsDocument:true to the second core results web part and position it in the usual spot
      • Hide the first core results webpart (hidden under the layouts area)

    So now I have best bets triggering off of the first result set and being displayed in the best bets web part, but my second filtered core results web part is showing the filtered query set.

    http://iedaddy.com/2012/10/sharepoint-2010search-core-results-append-text-to-query-causes-best-bets-not-to-display/

    No code solution seems better than cracking open Visual Studio...

    • Proposed as answer by ieDaddy Wednesday, October 10, 2012 5:50 PM
    Wednesday, October 10, 2012 5:43 PM
  • Hi,

    Nice!

    Thanks,
    Mikael Svenson


    Search Enthusiast - SharePoint MVP/MCT/MCPD - If you find an answer useful, please up-vote it.
    http://techmikael.blogspot.com/
    Author of Working with FAST Search Server 2010 for SharePoint

    Wednesday, October 10, 2012 6:41 PM
  • Mikael,

    Having two Core Results on the same page, doesn't it cause two queries to be sent to FAST?

    Amir

    Thursday, October 11, 2012 7:57 AM
  • Hi,

    Yes, but two searches are cheap :) You could even tune the "best bet one" to only return one result and turn off stemming etc to make it as light weight as possible since you don't care about the actual results being pulled back. It might even work to set a scope to it which is formed to not return any items at all. That last part would be interesting to try out.

    Regards,
    Mikael Svenson


    Search Enthusiast - SharePoint MVP/MCT/MCPD - If you find an answer useful, please up-vote it.
    http://techmikael.blogspot.com/
    Author of Working with FAST Search Server 2010 for SharePoint

    Thursday, October 11, 2012 8:14 AM
  • It certainly is cheap for a dev perspective and keeps everything OOB. Since I didn't want to relink the paging and result numbers I kept the number of reaults displayed in core results the same as the hidden core results.
    Thursday, October 11, 2012 4:59 PM