Could you tokenize the query string, remove the noise words yourself then reconstruct a string without the moise words and use that to query ?
-----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Pragya Kapoor Sent: Friday, June 04, 2010 7:14 AM To: [email protected] Subject: Re: [MarkLogic Dev General] Ignoring customized noise words inelement value query Hi Danny, I can't use the element-word-query in place of element-value-query as I have to look for exact match ignoring the noise words. Is it possible? Thanks, Pragya Date: Thu, 3 Jun 2010 17:17:46 -0700 From: Danny Sokolsky <[email protected]> Subject: Re: [MarkLogic Dev General] Ignoring customized noise words in element value query To: General Mark Logic Developer Discussion <[email protected]> Message-ID: <[email protected]> Content-Type: text/plain; charset="iso-8859-1" Hi Pragya, If you are going to do this, I would not use an element-value-query. There is no concept of "noise words", and the phrase "rented house in delhi" does not match "rented house delhi". If you want that to match, I would use an element-word-query instead and not pass it a phrase. Something like: cts:and-query(( let $y := "Rented House in Delhi" for $x in fn:tokenize($y, " ") return cts:element-word-query(xs:QName("title"),$x) )) -Danny From: [email protected] [mailto:[email protected]] On Behalf Of Pragya Kapoor Sent: Thursday, June 03, 2010 2:50 AM To: [email protected] Subject: [MarkLogic Dev General] Ignoring customized noise words in element value query Hi, I have to ignore the noise words(this would be a list of words which I give) in element value query. Eg: Rented house in Delhi(title) Now user types in Rented House Delhi/Rented House in Delhi Both query should give the result. So, how can I include such a query in my additional query to make this work. <additional-query> ????? ????? ??? { ????? ????? ?????? ????? ???????????????? cts:element-value-query(xs:QName("title"),$search, ("case-insensitive","unstemmed")) ????? ????? ????? ???? } </additional-query> Please let me know how this can be achieved. Thanks, Pragya _______________________________________________ General mailing list [email protected] http://developer.marklogic.com/mailman/listinfo/general _______________________________________________ General mailing list [email protected] http://developer.marklogic.com/mailman/listinfo/general
