Click to See Complete Forum and Search --> : multiple conditions: xsl:choose


sawyer1370
October 9th, 2003, 03:25 PM
I have a set of xml date that I would like to format. I would like to have all the info for each "Region" be put together. So the report would look like the example below. I think I need to use something similiar to:

xsl:when region=fl ...
xsl:otherwise

region severity average BaseAbHigh

fl ok 10 50
minor 12 51
ok 11 55
ok 10 50
dc ok 15 50
ok 13 60
ok 10 55

I hope I explained that correctly.

khp
October 9th, 2003, 03:57 PM
What is the question ?
How is the source data formatted ?

sawyer1370
October 10th, 2003, 07:45 AM
I am looking for the code for the xsl to format the data like the example given.

khp
October 10th, 2003, 04:00 PM
Originally posted by sawyer1370
I am looking for the code for the xsl to format the data like the example given.
I thought you were dooing quite well with

xsl:when region=fl ...
xsltherwise


OK more formally speaking it could be something like.


<xsl:choose>
<xsl:when test="region='fl'">
<xsl:text>fl</xsl:text>
...
</xsl:when>
<xsl:otherwise>
...
</xsl:otherwise>
</xsl:choose>


But without knowing anything about the format of the source document I can't go into any futher details.