xsl-list
[Top] [All Lists]

Re: [xsl] XPath related query

2011-01-23 10:27:17
On Sun, 23 Jan 2011 14:14:50 +0000 (GMT)
Florent Georges <lists(_at_)fgeorges(_dot_)org> wrote:

Vineet Chaoji wrote:

  Hi,

So the query that I am trying to represent is: Is there a Book
"Book1" that has a chapter 'c1' that cites some article 'a' and
does this article 'a' have a chapter 'c2' which has a section
's' which has a figure 'f' which is called "Example semi-joins".
This is a binary yes/no type of query.

  Given that $dblp is bound to the element DBLP, the following
expression should return what you are looking for, and is I think
self-explanatory:

    exists(
      $dblp
        /Book[@rdf:about eq 'Book1']
        /chapter
        /Chapter[@rdf:about eq 'c1']
        /section
        /Section
        /cites[@rdf:resource eq 'a']
        /../../../../../..
        /Article[@rdf:about eq 'a']
        /chapter
        /Chapter[@rdf:about eq 'c2']
        /section
        /Section[@rdf:about eq 's']
        /figure[. eq '"Example Semi-join"']
    )

  Regards,



I guess this is why we choose XSLT Florent?




-- 

regards 

-- 
Dave Pawson
XSLT XSL-FO FAQ.
http://www.dpawson.co.uk

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>