Jakob, I think those options may only affect how it matches, but will still return dupes if they are in the suggestion source. Is the word lexicon for suggest-field using a case insensitive collation?
Regards, Will -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Jakob Fix Sent: Wednesday, April 11, 2012 4:38 PM To: General Mark Logic Developer Discussion Subject: [MarkLogic Dev General] case sensitivity and search:search Hello, my goal is to search a couple of elements for the type-ahead (aka search:suggest) and to return suggestions. I've created a word field index (called "suggest-field") based on the two elements. The search has to be case insensitive, i.e. currently I get results like this: env ENV envahissantes envahisseur envejece for the first two, I want only "env", not "ENV" or a potential "Env". I've disabled "fast case sensitive searches" on the database level as otherwise this was inherited by the field configuration. I have the basic collation (http://marklogic.com/collation/). Also, I'm using a term-option set to "case-insensitive" (see sample query below). But none of these options make that the search considers different case irrelevant. Which knob do I have to twiddle? let $options := <search:options xmlns="http://marklogic.com/appservices/search"> <default-suggestion-source> <word> <field name="suggest-field"/> </word> </default-suggestion-source> <term> <term-option>case-insensitive</term-option> </term> </search:options> return search:suggest("env", $options, 5) cheers, Jakob. _______________________________________________ General mailing list [email protected] http://developer.marklogic.com/mailman/listinfo/general _______________________________________________ General mailing list [email protected] http://developer.marklogic.com/mailman/listinfo/general
