[xsl] How to transform a huge XML-file (memory-saving)?

Subject: [xsl] How to transform a huge XML-file (memory-saving)?
From: news@xxxxxxxxxxx
Date: Tue, 9 Aug 2005 15:49:11 +0200
Hello List,

i'm looking for a solution to handle the xslt-transformation of huge data
If i try to process a 176 mb XML-file with saxon8, the java enviroment uses
a lot of main-memory - round about 1 gb.
This XML-file contains a always repeating block of a structure like this:


To process this XML-structure, i used a normal template structure like this:

<xsl:template match="/">  
  <!--<xsl:call-template name="XmlInfo"/>-->  
  <xsl:apply-templates select="//OBJECT" mode="Bestimmungen"/>  

<xsl:template match="OBJECT" mode="Bestimmungen">

I expect to get a much larger data-file soon. So i think, i will get a
problem with the main memory capacity.
To split the file isn't a possibility, because i have to link between the

Has anybody an idea, whether an more effective (less memory) way of
programming exists?

I tried to use <xsl:key ...> and the key()-function to built an index. But
it doesn't fit in the <xsl:template ...> - enviroment.
Is it possible to bring both concepts together?

Thanks a lot!

Current Thread