how to look up the result-tree of an XSL-transformation?

Discussion in 'XML' started by Johannes Busse, Jul 1, 2003.

  1. Hello NG,

    a short question: is it possible to look up the result-tree of an
    XSL-transformation also?

    We have the problem to process a literature-database:
    - write out an entry for each book (trivial)
    - write out an entry for each author of the book (trivial)
    *if and only if this author was not allocated yet*.

    We have solved this problem yet like this:

    <xsl:template match="author">
    <xsl:choose>
    <xsl:when test=" preceding-sibling::BookEntry/author = .">
    <!-- we have had processed this author yet;
    nothing to do -->
    </xsl:when>
    <xsl:eek:therwise>
    <!-- allocate the author -->
    </xsl:eek:therwise>
    </xsl:choose>
    </xsl:template>

    That' fine, it works. But in other cases it would be much more easy to
    look up the result-tree. Is it possible?

    Thank you!



    herzliche Grüße
    Johannes Busse
    Johannes Busse, Jul 1, 2003
    #1
    1. Advertising

  2. This is a grouping problem -- you can use for example the Muenchian method
    for grouping.


    =====
    Cheers,

    Dimitre Novatchev.
    http://fxsl.sourceforge.net/ -- the home of FXSL



    "Johannes Busse" <-heidelberg.de> wrote in message
    news:-heidelberg.de...
    Hello NG,

    a short question: is it possible to look up the result-tree of an
    XSL-transformation also?

    We have the problem to process a literature-database:
    - write out an entry for each book (trivial)
    - write out an entry for each author of the book (trivial)
    *if and only if this author was not allocated yet*.

    We have solved this problem yet like this:

    <xsl:template match="author">
    <xsl:choose>
    <xsl:when test=" preceding-sibling::BookEntry/author = .">
    <!-- we have had processed this author yet;
    nothing to do -->
    </xsl:when>
    <xsl:eek:therwise>
    <!-- allocate the author -->
    </xsl:eek:therwise>
    </xsl:choose>
    </xsl:template>

    That' fine, it works. But in other cases it would be much more easy to
    look up the result-tree. Is it possible?

    Thank you!



    herzliche Grüße
    Johannes Busse
    Dimitre Novatchev, Jul 1, 2003
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    1
    Views:
    3,582
    A. Bolmarcich
    May 27, 2005
  2. Replies:
    0
    Views:
    519
  3. Stub

    B tree, B+ tree and B* tree

    Stub, Nov 12, 2003, in forum: C Programming
    Replies:
    3
    Views:
    10,087
  4. Luke Graham

    tree transformation insight required

    Luke Graham, Mar 9, 2005, in forum: Ruby
    Replies:
    7
    Views:
    103
    Luke Graham
    Mar 18, 2005
  5. Michael Tan
    Replies:
    32
    Views:
    925
    Ara.T.Howard
    Jul 21, 2005
Loading...

Share This Page