Subject: RE: [xsl]: XSL processes XML incorrectly when uneven number of values returned in array elements From: "Cave, Neil" <Neil.Cave@xxxxxxxxxxxxxx> Date: Fri, 10 Mar 2006 14:24:29 +0100 |
The back-end app has an array structure of [1:50] for each of these optionList elements. When I created the XML wrapper for the back-end app with the middleware I opted for Null Value Suppression on array elements that trims the cells at the end. So there will be between 0 and 50 occurrences. I can't enforce the XML wrapper to return the same number of array elements (/option) for each /optionList* parent. So what I get is if there are 3 values for optionList1 I get 3 child elements, whereas optionList2 may have more, it will always be uneven. -----Original Message----- From: cknell@xxxxxxxxxx [mailto:cknell@xxxxxxxxxx] Sent: 10 March 2006 03:08 PM To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Subject: RE: [xsl]: XSL processes XML incorrectly when uneven number of values returned in array elements Is there a maximum number of <option> children in an <optionListx> element, or could there be an indefinite number of columns in the output table? We've already determined that there should be exactly seven rows (one for each <optionListx> element). The task becomes very easy if there is a maximum number of columns and very tricky if the number of columns is indeterminate. Please advise. -- Charles Knell cknell@xxxxxxxxxx - email -----Original Message----- From: Cave, Neil <Neil.Cave@xxxxxxxxxxxxxx> Sent: Fri, 10 Mar 2006 13:44:53 +0100 To: <xsl-list@xxxxxxxxxxxxxxxxxxxxxx> Subject: RE: [xsl]: XSL processes XML incorrectly when uneven number of values returned in array elements Hi Charles I can try give it a go with 2.0 Alternatively, if I absolutely have to, I can modify the XSL that transforms the XML from the back-end application to the XML required by the front-end app. The front-end app requires data in the free-xml/optionList/option format. However, the front-end app will accept the data as attributes or elements. I went with elements because I could not figure out how to map the elements of the XML from the back-end app to the attributes of the front-end XML using my XSL tool. I had some XSL that displayed the data correctly when I used a test XML document where the data was returned as attributes as in the structure below. <free-xml> <optionList1> <option desc="92" value="1"/> <option desc="101" value="2"/> </optionList1> Etc... However, because of my limited XSL skills I could only create the integration XSL (using a tool) that returns the back-end data as elements <free-xml> <optionList1> <option>92</option> <option>101</option> </optionList1> Etc... But now I sit with this display issue...
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl]: XSL processes XML incor, Cave, Neil | Thread | RE: [xsl]: XSL processes XML incor, Cave, Neil |
RE: [xsl]: XSL processes XML incor, cknell | Date | RE: [xsl]: XSL processes XML incor, cknell |
Month |