Free text search on specific field
I have marked a few fields as searchable. Is it possible to use free text search only on a specific field marked as searchable? For example, if I maked ingredients and description as searchable, but I only want to search ingredients.
[241 byte] By [
dmsy] at [2008-1-9]
I haven't tried this yet but I think you can use the CatalogSearchOptions.PropertiesToReturn to "set" which fields are searched. The "null" value returns all searchable properties.
You might also be able to do thisusing the CatalogSearch.SqlWhereClause property.
Jeff Lynch
MVP Windows Server System - Commerce Server
http://codebetter.com/blogs/jeff.lynch
When creating\modifying a property you can specify only a “Free Text Searchable” or “Specification Searchable”. Since you haven’t specified which search method you have select I am going to make an assumption that it’s “Free Text Searchable”.
That said when you enable one or more property for “Free Text Searchable” and perform a search you can't choose which property to search, when calling the API to search it will search both of your fields if you are using the “UseAdvancedFreeTextSearch” to true.
You can use Jeff’s solution to do keyword searches but it will not use SQL Full Text.
Good luck,
-Max