Hi Andrew,

Thank you for suggestion. Your solution working fine.

the same options set i used for resolve-nodes(), where the collection
condition not effecting.

I can go for search:search() function, but here the outpur i

---> search:resolve-nodes(search:parse("",$options))



> ------------------------------
>
> Message: 2
> Date: Wed, 10 Feb 2010 09:17:40 +0000
> From: Andrew Welch <[email protected]>
> Subject: Re: [MarkLogic Dev General] library search
> To: General Mark Logic Developer Discussion
>        <[email protected]>
> Message-ID:
>        <[email protected]>
> Content-Type: text/plain; charset=ISO-8859-1
>
> Hi,
>
> Do you have the collection lexicon enabled for that database?
>
> An alternative approach which doesn't require that is to use:
>
> <searchable-expression>fn:collection('/source/Sciences')</searchable-expression>
>
> cheers
> andrew
>
>
> On 10 February 2010 07:55, Arpitha Chittumalla <[email protected]> 
> wrote:
>> Hi,
>> I am trying to search a value in the specfic collection.But the
>> following  query resluts comming from other collection document also(
>> which has different uri)
>> can any one give me suggestion.
>>
>> xquery version "1.0-ml";
>> import module namespace search = "http://marklogic.com/appservices/search";
>>    at "/MarkLogic/appservices/search/search.xqy";
>> let $options :=<options xmlns="http://marklogic.com/appservices/search";>
>>
>>    <constraint name="subject">
>>       <value>
>>          <element ns="http://purl.org/dc/elements/1.1/"; name="subject"/>
>>       </value>
>>   </constraint>
>> <constraint name="myCollection">
>>    <collection prefix="/source/Sciences"/>
>> </constraint>
>>
>>    </options>
>> return
>>  search:search("subject:math",$options)
>> _______________________________________________
_______________________________________________
General mailing list
[email protected]
http://xqzone.com/mailman/listinfo/general

Reply via email to