Re: [MarkLogic Dev General] String Array query

2010-06-09 Thread Pragya Kapoor
** End of Disclaimer INFOSYS*** -- next part -- An HTML attachment was scrubbed... URL: http://developer.marklogic.com/pipermail/general/attachments/20100609/40634243/attachment.html -- ___

Re: [MarkLogic Dev General] Search API snippet

2010-06-09 Thread Shannon
Pradeep, as a work-around to the undesired behavior, I modified asc:transform-result in standard.xqy, to inspect each result, and if the query is found only in an element that contains metadata, which is unsuitable for display in results, then my preferred element is returned instead (convenient

Re: [MarkLogic Dev General] Search:Suggest and Internationalized documents

2010-06-09 Thread Stewart Shelline
I believe you can specify a language in the options, or create a constraint on whatever element or attribute specifies your language. From: general-boun...@developer.marklogic.com [mailto:general-boun...@developer.m

Re: [MarkLogic Dev General] Search:Suggest and Internationalized documents

2010-06-09 Thread spig
Just wondered if anyone had any ideas, or if this is possible. Is there a way to specify a searchable-expression for suggestion-source or default-suggestion-source? -- Steve On Tue, Jun 8, 2010 at 2:27 PM, spig wrote: > I am trying to use search:suggest and am having a minor issue where > som

[MarkLogic Dev General] using input from XForm "input" in xquery

2010-06-09 Thread Steiner, David J. (LNG-DAY)
Ok, I'm not well versed in HTML, Javascript, CSS, etc., so I thought I'd try XForms. I am not getting how to use the "input" I get from a user and "pass" that string of text to an XQuery, then use the result of an XQuery as the "output" in the XForm. Scenario: User enters a string of text.

[MarkLogic Dev General] nested fragment roots and facet counts

2010-06-09 Thread Lisa Liddle
I have a fragment root on para and one on topicBlock (because both are used in the searchable-expression in search:search). There are some documents that have para elements inside of a topicBlock element and I've found that if the search term appears in a para element inside a topicBlock element

Re: [MarkLogic Dev General] Search API snippet

2010-06-09 Thread Shannon
Yes, that is true -- I reported it back in April. It is bug report #10005: "search:snippet does not return snippets in the preferred elements". I was told the engineering team will review the case and address it in a future maintenance release. On Jun 9, 2010, at 12:14 PM, Pradeep Maddireddy wr

Re: [MarkLogic Dev General] Search API snippet

2010-06-09 Thread Pradeep Maddireddy
Hi Shanon That mapping helps only if the search term is found in multiple elements, it will return all those elements, we can also control the element to be preferred. But in my case, if the search term is only found in title and no where else, search API only returns the title element as snipp

Re: [MarkLogic Dev General] Search API snippet

2010-06-09 Thread Shannon
Hi Pradeep, Check out section 2.2.6.1 of Search Developer's Guide: max-snippet-chars and preferred-elements child elements of the transform-results options node should address those requirements. Best, Shannon On Jun 9, 2010, at 10:48 AM, Pradeep Maddireddy wrote: > Hi..! > > I always want

[MarkLogic Dev General] Search API snippet

2010-06-09 Thread Pradeep Maddireddy
Hi..! I always want atleast 300 to 400 char of snippet to be returned by the search API. Is there any setting that would help me get 300 to 400 char of snippet. Most of the times when the hit is aginst a title or author element only that particular element is being returned as snippet, this wi

Re: [MarkLogic Dev General] String Array query

2010-06-09 Thread Lee, David
I cant tell for sure as your attachment didnt make it to the list (or atleast my inbox). but my guess is that you are getting "document order". which is the default for xquery lists. Since all of the tokens are *nodes* (not strinngs) they have a document order which is preserved. Sugges

[MarkLogic Dev General] String Array query

2010-06-09 Thread Pragya Kapoor
Hi, I am using the attached file. Query : = ABC for $token in $suggestionsXML//title/text() return let $flag := fn:starts-with($token,$strsearch) let $result:= if($flag eq fn:true())then $token else () let $result2 := if(fn:compare($strsearch, $token)eq 1) then $token else