FullTextQuery errors when more than 10 properties in
the where clause.
We have successfully implemented a fulltextquery
webpart allowing users to add filter conditions based on multichoice properties
(mapped to managed properties). However
we have found that once a user selects more than 10 properties you get a “query
is malformed” error message.
This is a sample query:
SELECT WorkId, Rank, Title, Author, Size, Path,
Description, Write, SiteName, CollapsingStatus, HitHighlightedSummary,
HitHighlightedProperties, ContentClass, IsDocument, PictureThumbnailURL,
DocType, Year, Source FROM Scope () WHERE "scope" ='Reports') AND FREETEXT (defaultproperties, 'any') AND (
Geography ='Belgium' OR Geography ='Brazil' OR Geography ='Canada' OR
Geography ='Chile' OR Geography ='China' OR Geography ='Colombia' OR Geography ='Croatia') AND ( DocType ='Pulse
Documents' OR DocType ='Annual' OR DocType ='Country Reports' ) ORDER BY Rank
DESC
If you run this query we get results back however if
the user adds one more property selection e.g. one more country the results
error.
We’ve tried putting these into comparison arrays but
again the same error occurs.
I’ve checked in the advanced search web part (looking
at the executed query in the logs) and you can get a working query with a lot
more than 10 properties together.
Does anyone have any ideas as to what is doing
this????
There are only two times to go fishing,,, when it's raining,,, and when it isn't!!