<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
	xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format"
	xmlns:date="http://exslt.org/dates-and-times" xmlns:exsl="http://exslt.org/common"
	extension-element-prefixes="date exsl" xmlns:csv="csv:csv">


	<xsl:output method="text" encoding="ISO-8859-1" />
	<xsl:strip-space elements="*" />
	<xsl:variable name="delimiter" select="';'" />


	<xsl:template match="/">

		<xsl:text>"Kategorie"</xsl:text>
		<xsl:value-of select="$delimiter" />

		<xsl:text>"Gruppenname"</xsl:text>
		<xsl:value-of select="$delimiter" />
			
		<xsl:text>"Artikelnummer"</xsl:text>
		<xsl:value-of select="$delimiter" />

		<xsl:text>"Artikelname"</xsl:text>
		<xsl:value-of select="$delimiter" />

		<xsl:text>"Artikelgruppe"</xsl:text>
		<xsl:value-of select="$delimiter" />
		
		<xsl:text>"Archiviert"</xsl:text>
		<xsl:value-of select="$delimiter" />

		<xsl:text>&#xa;</xsl:text>


		<xsl:for-each select="/report/StatisticGroups/data/rows/row">

			<xsl:value-of select="catName" />
			<xsl:value-of select="$delimiter" />

			<xsl:value-of select="groupName" />
			<xsl:value-of select="$delimiter" />

			<xsl:value-of select="itemCd" />
			<xsl:value-of select="$delimiter" />

			<xsl:value-of select="itemName" />
			<xsl:value-of select="$delimiter" />

			<xsl:value-of select="itemPath" />
			<xsl:value-of select="$delimiter" />
		
			<xsl:value-of select="unselectable" />
			<xsl:value-of select="$delimiter" />

			<xsl:text>&#xa;</xsl:text>

		</xsl:for-each>
	</xsl:template>

</xsl:stylesheet>