[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: general purpose filter stylesheet

Subject: RE: general purpose filter stylesheet
From: "Jonathan C. Dietrich" <jcdietrich@xxxxxxxxxx>
Date: Thu, 14 Mar 2002 15:06:42 -0500
filter dietrich
Assuming  <article> as your scope.... 
I believe the correct paths would be....

((authors/author='Date' or title='Database Systems') and
../../number='1')

-----Original Message-----
From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx
[mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of Robert
Sösemann
Sent: March 14, 2002 2:39 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject:  general purpose filter stylesheet

How can I do this query resolving with XSLT?
(I need this for an java xml wrapper, that can submit queries to given
docs
without knowing a lot of their structure)

My query is an boolean expression:
###########################

((author='Date' or title='Database Systems') and number='1')
PROBLEM: 'number' is not part of the same parent as 'author'

My input XML look like this:
######################

<SigmodRecord>
    <issue>
        <volume>12</volume>
        <number>1</number>
        <articles>
            <article>
                <authors>
                    <author>Date</author>
                    <author>Knuth</author>
                <authors>
                <title>Database Systems</title>
            </article>
            <article>
                <authors>
                    <author>Horak</author>
                    <author>Elmasri</author>
                <authors>
                <title>Database Systems</title>
            </article>
            *more articles*
        </articles>
    </issue>
    <issue>
   ...
    </issue>
    *more issues*
</SigmodRecord>

The result doc should have the same structure as the source but filter
out
nodes that don't make sense:

########################################################################
####

<SigmodRecord>
    <issue>
        <volume>12</volume>
        <number>1</number>
        <articles>
            <article>
                <authors>
                    <author>Date</author>
                    <author>Knuth</author>
                <authors>
                <title>Database Systems</title>
            </article>
        </articles>
    </issue>
</SigmodRecord>

It would be great I somebody could help me out. This is part of a
university
project.
Thanks Robert.

........................................................................
....
..........
 ROBERT SÖSEMANN  (robert.soesemann@xxxxxx)

 schwärzlocherstr. 29/1 | 72070 tübingen
 tel : 07071 / 400 880

 icq# : 100 467 870
 pgp-keys : www.webspace-journey.de/pgp.asc
........................................................................
....
..........


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.