In this post, we will see how to resolve Can XSLT detect the version of the Saxon engine being used? Question: I have a third party application that is using the Saxon XSLT transformation engine. Let’s call it Application X. ...
In this post, we will see how to resolve Reference the current node in a document tree, which is stored in a variable Question: I have a stylesheet in which I loop through a Day-Element. For each day, I need ...
Question: I’m using Saxon-HE (11.3) for validating xml using external xsd. But I’m getting nullpointerexception as schemaManager is null. Processor processor = new Processor (false); SchemaManager manager = processor.getSchemaManager(); manager.load(new StreamSource("xsdFile)); Getting NPE on 3rd line. I’m not getting why ...
Question: I’m using Saxon-HE (11.3) for validating xml using external xsd. But I’m getting nullpointerexception as schemaManager is null. Processor processor = new Processor (false); SchemaManager manager = processor.getSchemaManager(); manager.load(new StreamSource("xsdFile)); Getting NPE on 3rd line. I’m not getting why ...
Question: XSLT 3 is causing “SENR0001: Cannot serialize a map using this output method” error while transforming JSON natively using Saxon EE library capabilities ( ‘saxon:with-pedigree’ , ‘saxon:pedigree(.)?container, and ‘deep-update’). Below XSLT identifies array objects with ‘visibility’ attribute value as ...
Question: We are trying to use Saxon EE in our Quarkus application compiled down into a native image. It looks like there is a lot of reflection going on in Saxon EE and we are fighting adding all these classes ...
Question: I need to replace all ? in file1.xml with element value present in File2.xml. And also need to remove extra element node present in File1.xml whose value is not present in File2.xml. (i.e. In my sample input need to ...
Question: On the xml-dev list Michael Kay wrote: In the XDM model the content of the Test element is a single text node. XDM does not allow two adjacent text nodes. I believe SAXON uses the XDM model. Consider this ...
Question: so I’m having weird problems with an XSL transformation. I am trying to get distinct values from files in a folder. Path to objects in folder: <xsl:variable name="objects" select="collection('../../../../data/objects')"/> Variable for distinct values: <xsl:variable name="something" select="$objects//tei:rs[@type='something' and @subtype='something']/@ref" as="xs:string"/> ...
Question: Input: Expected Output: How to use apply-templates to generate same random number for every bq and eq set? Answer: In XSLT 3 (e.g. with random-number-generator) it would boil down to That requires Saxon HE 10 or later or Saxon ...