RE: [xsl] Querying the Result Document

Subject: RE: [xsl] Querying the Result Document
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Thu, 22 Dec 2005 00:27:08 -0000
> Is there a way to check the Result Document for a set of nodes.

Only by turning your transformation into a multi-phase one in which the
result document of the first phase becomes the input document to the second.
> 
> What I want to do is make sure that I don't add a duplicate 
> node to the 
> result document, when an earlier template may have already 
> added the result.
> 

The word "earlier" gives away that you're thinking procedurally. XSLT is a
functional language, the output has to be expressed as a function of the
input, not as a function of things that happened "earlier", because there is
no defined order of execution.

If you can't express the logic as a function of the original input, then use
a multi-phase transformation.

Michael Kay
http://www.saxonica.com/

Current Thread