[xquery-talk] Optimal expression for gathering related elements

Michael Kay mike at saxonica.com
Wed Mar 2 10:35:44 PST 2011

> Performance wise I tested my code (XQuery 1) vs XSLT 2 code doing the 
> same thing (using for-each-group) using Saxon 9.3 HE
> This was using a 200MB XML file with about 17,000 ungrouped elements 
> and 4,000 grouped elements.
> XSLT2 took about 6 seconds
> XQuery took about 4 minutes.

Saxon-EE's join optimizer should handle this query quite well, and 
produce the result in a time that isn't too far off the XSLT figure. 
This is the kind of query where a more powerful optimizer can make a big 
difference, especially with large input files.

End of sales pitch.

Michael Kay
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://x-query.com/pipermail/talk/attachments/20110302/49b86243/attachment.htm

More information about the talk mailing list