Today when I was trying to do a FullTextSqlQuery and I got the following error. It was very strange.
“Microsoft.SharePoint.SPException: Your search cannot be completed because this site is not assigned to an indexer. Contact your administrator for more information. at Microsoft.SharePoint.Search.Query.Query.CreateQueryProxy(SPSite site) at Microsoft.SharePoint.Search.Query.Query..ctor(SPSite site)”
After some research I found that I needed to change the reference Microsoft.SharePoint.Search.Query to Microsoft.Office.Server.Search.Query. After I did that the problem was fixed.
Microsoft.SharePoint.Search.Query must be for SharePoint Foundation 2010 and Microsoft.Office.Server.Search.Query for SharePoint Server 2010. So it makes sense.
e7f1541f-6dbd-4145-8dfc-8607d57b7d0d|4|4.0