cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Conal Tuohy" <con...@paradise.net.nz>
Subject RE: XSLT exception: bug or my mistake
Date Wed, 01 May 2002 22:28:41 GMT
double equal signs in the xpath expression? 

> -----Original Message-----
> From: Alex McLintock [mailto:alex@OWAL.co.uk]
> Sent: Thursday, 2 May 2002 08:32
> To: cocoon-users@xml.apache.org
> Subject: XSLT exception: bug or my mistake
> 
> 
> Hi folks,
> 
> I am getting data from XIndice and piping it through Cocoon. 
> I'm getting an 
> exception I don't understand when I do something particular in XSLT.
> 
> 
> 
> I have a bunch of book reviews in my XML database and am 
> listing the book 
> authors. I'm using the "not preceding" trick to remove 
> duplicate authors. 
> This works.
> 
> I'm now trying to list the number of reviews we have for each 
> of those 
> unique authors.
> 
> I'm doing this with two variables - one is the current author 
> fullname, and 
> the other is supposed to be the count of reviews with that 
> author. So I'm 
> doing this
> 
>            <xsl:variable name="thisauthor">
>              <xsl:value-of select="fullname"/>
>            </xsl:variable>
> 
>            <xsl:variable name="numarticles">
>              <xsl:value-of 
> select="count(//author[fullname==$thisauthor])"/>
>            </xsl:variable>
> 
> Now I'm pretty sure I've got this count line wrong, but 
> should it cause the 
> following exception?
> 
> org.apache.cocoon.ProcessingException: Exception in creating 
> Transform 
> Handler: java.lang.RuntimeException: Programmer's assertion in 
> getNextStepPos: unknown stepType: -1
> 
> If I comment out the count line I don't get the exception.
> 
> Any ideas for a relevant tutorial, or can anyone see what I'm 
> doing wrong.
> 
> 
> 
> This is the basic structure of the xml I'm processing.
> 
> <collection:results>
> <collection:result>
> <review>
> <author>
> <fullname>
> etc etc
> 
> 
> I'm using a CVS build of Cocoon which is several weeks old. Tomcat 
> 4.0.something, Java 1.3, RedHatLinux 7.2
> 
> 
> org.apache.cocoon.ProcessingException: Exception in creating 
> Transform 
> Handler: java.lang.RuntimeException: Programmer's assertion in 
> getNextStepPos: unknown stepType: -1
> at 
> org.apache.cocoon.components.xslt.XSLTProcessorImpl.getTransfo
> rmerHandler(XSLTProcessorImpl.java:276)
> at 
> org.apache.cocoon.transformation.TraxTransformer.setup(TraxTra
> nsformer.java:306)
> at 
> org.apache.cocoon.components.pipeline.AbstractEventPipeline.se
> tupPipeline(AbstractEventPipeline.java:215)
> at 
> org.apache.cocoon.components.pipeline.CachingEventPipeline.set
> up(CachingEventPipeline.java:278)
> at 
> org.apache.cocoon.components.pipeline.CachingEventPipeline.gen
> erateKey(CachingEventPipeline.java:141)
> at 
> org.apache.cocoon.components.pipeline.CachingStreamPipeline.pr
> ocess(CachingStreamPipeline.java:320)
> at 
> org.apache.cocoon.components.treeprocessor.sitemap.SerializeNo
> de.invoke(SerializeNode.java:153)
> at 
> org.apache.cocoon.components.treeprocessor.AbstractParentProce
> ssingNode.invokeNodes(AbstractParentProcessingNode.java:85)
> at 
> org.apache.cocoon.components.treeprocessor.sitemap.PreparableM
> atchNode.invoke(PreparableMatchNode.java:156)
> at 
> org.apache.cocoon.components.treeprocessor.AbstractParentProce
> ssingNode.invokeNodes(AbstractParentProcessingNode.java:109)
> at 
> org.apache.cocoon.components.treeprocessor.sitemap.PipelineNod
> e.invoke(PipelineNode.java:140)
> at 
> org.apache.cocoon.components.treeprocessor.AbstractParentProce
> ssingNode.invokeNodes(AbstractParentProcessingNode.java:109)
> at 
> org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNo
> de.invoke(PipelinesNode.java:144)
> 
> 
> 
> 
> 
> 
> 
> 
> 
> Openweb Analysts Ltd, London: Software For Complex Websites 
> http://www.OWAL.co.uk/
> Free Consultancy for London Companies thinking of Open Source 
> Software.
> 
> 
> ---------------------------------------------------------------------
> Please check that your question has not already been answered in the
> FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
> 
> To unsubscribe, e-mail: <cocoon-users-unsubscribe@xml.apache.org>
> For additional commands, e-mail: <cocoon-users-help@xml.apache.org>
> 
> 

---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail: <cocoon-users-help@xml.apache.org>


Mime
View raw message