Hi,

Jumping in in the middle, so I may be way out of line. Just having a wild 
thought:

Isn't it possible to simply restrict on parent element by using a 
cts:element-query? Which can be wrapped in another one to limit on parent-child 
relations..

Kind regards,
Geert

>


Drs. G.P.H. Josten
Consultant


http://www.daidalos.nl/
Daidalos BV
Source of Innovation
Hoekeindsehof 1-4
2665 JZ Bleiswijk
Tel.: +31 (0) 10 850 1200
Fax: +31 (0) 10 850 1199
http://www.daidalos.nl/
KvK 27164984
De informatie - verzonden in of met dit emailbericht - is afkomstig van 
Daidalos BV en is uitsluitend bestemd voor de geadresseerde. Indien u dit 
bericht onbedoeld hebt ontvangen, verzoeken wij u het te verwijderen. Aan dit 
bericht kunnen geen rechten worden ontleend.


> From: [email protected]
> [mailto:[email protected]] On Behalf Of
> Whitby, Rob, CMG
> Sent: woensdag 15 juli 2009 17:32
> To: General Mark Logic Developer Discussion
> Subject: RE: [MarkLogic Dev General] RE: General Digest, Vol
> 61, Issue 17
>
> I find this is a common annoyance - end up having to create a
> new element in another namespace specifically for indexing.
>
> If only you could specify a path when defining indexes rather
> than just the element name...
>
>
>
> -----Original Message-----
> From: [email protected]
> [mailto:[email protected]] On Behalf Of
> Runstein, Robert E. (Contr) (IS)
> Sent: 15 July 2009 16:19
> To: [email protected]
> Subject: [MarkLogic Dev General] RE: General Digest, Vol 61, Issue 17
>
> Hi Danny,
>
> I need a facet to be generated for my:a my:name that excludes
> my:b my:name, so indexing my:a wouldn't give me that.
>
> Bob
>
> >Hi Bob,
> >
> >Another idea is to try and create the range index on the parent
> elements instead of on the my:name element.  In your example,
> you could create 2 indexes on:
>
> >my:a
> >my:b
>
> >Then when you wanted to look for the a's, do a
> cts:element-value-match
> against my:a, and against my:b to look for b's.
>
> >It should index the string value of my:a and my:b, which is the
> equivalent of doing an fn:data(/path/to/my:a).
>
> >I am not sure this will work, but seems worth a try.
>
> >-Danny
>
> -----Original Message-----
> From: [email protected]
> [mailto:[email protected]] On Behalf Of
> Runstein, Robert E. (Contr) (IS)
> Sent: Friday, July 10, 2009 2:21 PM
> To: [email protected]
> Subject: [MarkLogic Dev General] Re: Restricting an element
> range index to a child of another element
>
> Unfortunately not.
>
> Bob
>
> >Can you add an attribute to the elements you want included?  A field
> word lexicon has support for including only
> >those elements with a certain attribute.
>
>
>
> On Jul 9, 2009, at 2:58 PM, "Runstein, Robert E. (Contr) (IS)"
> <[email protected]  > wrote:
>
> > Hi,
> >
> > I have documents like the following:
> >
> > <my:doc>
> >   <my:a>
> >     <my:name>Bob</my:name>
> >   </my:a>
> >   <my:b>
> >     <my:name>George</my:name>
> >   </my:b>
> > </my:doc>
> >
> > I would like to create an element range index that will index the
> > my:name values under my:a, but not the my:name values under my:b
> >
> > I cannot change the namespaces to differentiate between them.  Is
> > there a way to do this or do I have to index all the my:name values
> > and filter out the ones that came from the my:b element?  Thanks.
> >
> > Bob
> _______________________________________________
> General mailing list
> [email protected]
> http://xqzone.com/mailman/listinfo/general
> _______________________________________________
> General mailing list
> [email protected]
> http://xqzone.com/mailman/listinfo/general
>

_______________________________________________
General mailing list
[email protected]
http://xqzone.com/mailman/listinfo/general

Reply via email to