Skip to content

Instantly share code, notes, and snippets.

@msaraiva
Created February 26, 2014 11:23
Show Gist options
  • Save msaraiva/9227827 to your computer and use it in GitHub Desktop.
Save msaraiva/9227827 to your computer and use it in GitHub Desktop.
<?xml version="1.0" encoding="UTF-8"?>
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="report1" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="a5921604-8860-49b3-a881-cb9a53430761">
<property name="ireport.zoom" value="1.0"/>
<property name="ireport.x" value="0"/>
<property name="ireport.y" value="0"/>
<subDataset name="dataset1" uuid="199196fa-2855-4590-81bd-59a0831c61a4">
<queryString language="xPath">
<![CDATA[/parents/parent/children/child]]>
</queryString>
<field name="name" class="java.lang.String">
<fieldDescription><![CDATA[name]]></fieldDescription>
</field>
<field name="id" class="java.lang.String">
<fieldDescription><![CDATA[id]]></fieldDescription>
</field>
</subDataset>
<subDataset name="dataset2" uuid="78b7be16-609f-40fb-9967-dde8c49a649d">
<queryString language="xPath">
<![CDATA[/parents/parent/children/child/children/child]]>
</queryString>
<field name="id" class="java.lang.String">
<fieldDescription><![CDATA[id]]></fieldDescription>
</field>
<field name="name" class="java.lang.String">
<fieldDescription><![CDATA[name]]></fieldDescription>
</field>
</subDataset>
<queryString language="xPath">
<![CDATA[/parents/parent]]>
</queryString>
<field name="id" class="java.lang.String">
<fieldDescription><![CDATA[id]]></fieldDescription>
</field>
<field name="name" class="java.lang.String">
<fieldDescription><![CDATA[name]]></fieldDescription>
</field>
<background>
<band splitType="Stretch"/>
</background>
<title>
<band height="79" splitType="Stretch"/>
</title>
<pageHeader>
<band height="35" splitType="Stretch"/>
</pageHeader>
<columnHeader>
<band height="26" splitType="Stretch"/>
</columnHeader>
<detail>
<band height="26" splitType="Stretch">
<textField>
<reportElement uuid="a7d2c8f8-6016-4e44-95c0-e07bbfb0de6f" x="10" y="4" width="127" height="20"/>
<textElement/>
<textFieldExpression><![CDATA[$F{name}]]></textFieldExpression>
</textField>
<componentElement>
<reportElement uuid="2a6dfcc7-5301-4560-9561-fc6ca9d83d7e" x="0" y="1" width="555" height="22"/>
<jr:list xmlns:jr="http://jasperreports.sourceforge.net/jasperreports/components" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports/components http://jasperreports.sourceforge.net/xsd/components.xsd" printOrder="Vertical">
<datasetRun subDataset="dataset1" uuid="4cb1c3c0-f9e1-4e2e-b900-1c85c2503b24">
<dataSourceExpression><![CDATA[((net.sf.jasperreports.engine.data.JRXmlDataSource)$P{REPORT_DATA_SOURCE}).subDataSource("/parent/children/child")]]></dataSourceExpression>
</datasetRun>
<jr:listContents height="22" width="555">
<textField>
<reportElement uuid="faaede62-6c91-4391-8d9d-316def7cbcf6" x="141" y="2" width="147" height="20"/>
<textElement/>
<textFieldExpression><![CDATA[$F{name}]]></textFieldExpression>
</textField>
<componentElement>
<reportElement uuid="d3deeb68-c70f-4187-b977-f457dee15e72" x="292" y="2" width="256" height="20"/>
<jr:list printOrder="Vertical">
<datasetRun subDataset="dataset2" uuid="81494eba-486a-4e34-afce-a767b3edf45d">
<dataSourceExpression><![CDATA[((net.sf.jasperreports.engine.data.JRXmlDataSource)$P{REPORT_DATA_SOURCE}).subDataSource("/child/children/child")]]></dataSourceExpression>
</datasetRun>
<jr:listContents height="20" width="256">
<textField>
<reportElement uuid="ee361364-60c3-41e1-943b-97c3d113c9d6" x="0" y="0" width="100" height="20"/>
<textElement/>
<textFieldExpression><![CDATA[$F{name}]]></textFieldExpression>
</textField>
</jr:listContents>
</jr:list>
</componentElement>
</jr:listContents>
</jr:list>
</componentElement>
</band>
</detail>
<columnFooter>
<band height="45" splitType="Stretch"/>
</columnFooter>
<pageFooter>
<band height="54" splitType="Stretch"/>
</pageFooter>
<summary>
<band height="42" splitType="Stretch"/>
</summary>
</jasperReport>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment