none
FQL query error in scope RRS feed

  • Question

  • I want to create a scope that searches a specific contentsourse and  excludes one site.

    When I type

    +contentsource:Sites -site:http://mysite/subsite

    directly in the search textbox it gives me the right result

    but when i try to create the scope using powershell, sharepoint claims it is a wrong query...

    I've tried many options, none of them works:

    New-SPEnterpriseSearchQueryScope -SearchApplication "FastQuerySSA" -Name "AllExcludeConfigSite" -Description "Scope to search All Excludes One Site" -DisplayInAdminUI 1 –ExtendedSearchFilter "andnot(contentsource:Sites,site:http://mysite/subsite)"

    or:

    New-SPEnterpriseSearchQueryScope -SearchApplication "FastQuerySSA" -Name "AllExcludeConfigSite" -Description "Scope to search All Excludes One Site" -DisplayInAdminUI 1 –ExtendedSearchFilter ‘andnot(“contentsource:Sites”,”site:http://mysite/subsite”)'

    or I 've tried 'path' instead of 'site':

    New-SPEnterpriseSearchQueryScope -SearchApplication "FastQuerySSA" -Name "AllExcludeConfigSite" -Description "Scope to search All Excludes One Site" -DisplayInAdminUI 1 –ExtendedSearchFilter "andnot(contentsource:Sites,path:http://mysite/subsite)"

    Anyone knows what's the problem?

    thanks




    • Edited by malche Thursday, March 29, 2012 9:27 AM
    Thursday, March 29, 2012 9:24 AM

Answers

  • Hello,

    To identify the Fast Search components running on the system you can also use the following command

    nctrl status

    You are looking for

    Module Name                Process Name                       PID              Status

    QRServer                       qrserver                               ####           Running

    Best Wishes,

    Michael Puangco | Senior Support Escalation Engineer | US Customer Service & Support

    Customer Service & Support                         Microsoft| Services

    Sunday, April 1, 2012 7:04 PM
    Moderator
  • Hello,

    To identify the Fast Search components running on the system you can also use the following command

    nctrl status

    You are looking for

    Module Name                Process Name                       PID              Status

    QRServer                       qrserver                               ####           Running

    Best Wishes,

    Michael Puangco | Senior Support Escalation Engineer | US Customer Service & Support

    Customer Service & Support                         Microsoft| Services


    I found, thanks.
    • Marked as answer by malche Monday, April 2, 2012 1:43 PM
    Monday, April 2, 2012 1:43 PM

All replies

  • Hi malche,

    There's a difference in syntax when using KQL (used in the search box) and FQL (used in scope filter).

    contentsource stays the same AFAIK, but for anything that has to do with URLs use urls:<expression>, in your case:

    urls:starts-with("http://mysite/subsite");

    Also do notice the use of double quotes around strings.

    Every time you need to create an FQL expressions, use the QRserver to verify its integrity (http://localhost:13280).

    Amir

    • Proposed as answer by Amir at eWave Sunday, April 1, 2012 6:31 AM
    Thursday, March 29, 2012 10:13 AM
  • Thanks a lot, it worked out!

    but how do i use this QRserver? i have to install it? on the FAST server? my server?

    Thursday, March 29, 2012 11:09 AM
  • If you're using a single-node installation, it's simply on your one and only FAST Server.

    If you're using a multi-node installation, that's a bit more complicated, but you need to find which server runs the QRServer process.

    Once you find it, simply open a web-browser and go to http://localhost:13280

    Amir

    Sunday, April 1, 2012 6:33 AM
  • Hello,

    To identify the Fast Search components running on the system you can also use the following command

    nctrl status

    You are looking for

    Module Name                Process Name                       PID              Status

    QRServer                       qrserver                               ####           Running

    Best Wishes,

    Michael Puangco | Senior Support Escalation Engineer | US Customer Service & Support

    Customer Service & Support                         Microsoft| Services

    Sunday, April 1, 2012 7:04 PM
    Moderator
  • Hello,

    To identify the Fast Search components running on the system you can also use the following command

    nctrl status

    You are looking for

    Module Name                Process Name                       PID              Status

    QRServer                       qrserver                               ####           Running

    Best Wishes,

    Michael Puangco | Senior Support Escalation Engineer | US Customer Service & Support

    Customer Service & Support                         Microsoft| Services


    I found, thanks.
    • Marked as answer by malche Monday, April 2, 2012 1:43 PM
    Monday, April 2, 2012 1:43 PM
  • Hi,

    Make a note that querying directly against the QR server might yield zero results if you have items with security. This may be disabled for testing purposes by editing C:\FASTSearch\etc\qrserver\qtf-config.xml and commenting out the "securityfql" stage.

    Instead of using the QR Server interface I find it easier to use http://fastforsharepoint.codeplex.com/ for entering test FQL queries coupled with http://fs4splogger.codeplex.com/ on the server running the QR component to do my testing and verification.

    Regards,
    Mikael Svenson


    Search Enthusiast - SharePoint MVP/WCF4/ASP.Net4
    http://techmikael.blogspot.com/

    Monday, April 2, 2012 2:02 PM