How to make the row not repeating properly according the field - jasper-reports

i have create one statistical report according the gender.
The field names Jantina.
I have a problem when remove the Print repeating values. I just want the field is not repeating according the Jantina field. But unfortunately the row not repeating all the row without following the Jantina.
How to do that? Anyone got the idea?
This is my jrxml code:
<?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="penyata_bulanan_ikut_negeri_jantina_test" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20">
<parameter name="bulan" class="java.lang.Integer">
<defaultValueExpression><![CDATA[new Integer(-1)]]></defaultValueExpression>
</parameter>
<parameter name="tahun" class="java.lang.Integer">
<defaultValueExpression><![CDATA[new Integer(-1)]]></defaultValueExpression>
</parameter>
<parameter name="negeri" class="java.lang.Integer">
<defaultValueExpression><![CDATA[new Integer(00)]]></defaultValueExpression>
</parameter>
<parameter name="jantina" class="java.lang.Long">
<defaultValueExpression><![CDATA[new Long(2)]]></defaultValueExpression>
</parameter>
<queryString>
<![CDATA[SELECT #row := #row + 1 as r,bulan,tahun,negeri,jantina,
bilmale,jds,jumall,
ROUND(CAST((bilmale*100 /(jumall))AS DECIMAL(7,3)),2) as percent,
ROUND(CAST((jds*100 /(jumall))AS DECIMAL(7,3)),2) as p_jdk,
countstate
FROM some_table
group by date_format(X.createDate,'%Y' ),date_format(X.createDate,'%M' ),X.male,X.state
order by 1 asc) as a,(select #row := 0) as r]]>
</queryString>
<field name="r" class="java.lang.Long"/>
<field name="bulan" class="java.lang.String"/>
<field name="tahun" class="java.lang.String"/>
<field name="negeri" class="java.lang.String"/>
<field name="jantina" class="java.lang.String"/>
<field name="bilmale" class="java.math.BigDecimal"/>
<field name="jds" class="java.math.BigDecimal"/>
<field name="jumall" class="java.math.BigDecimal"/>
<field name="percent" class="java.math.BigDecimal"/>
<field name="p_jdk" class="java.math.BigDecimal"/>
<field name="countstate" class="java.lang.Long"/>
<sortField name="bulan"/>
<sortField name="tahun"/>
<sortField name="negeri"/>
<sortField name="jantina"/>
<group name="bulan">
<groupExpression><![CDATA[$F{bulan}]]></groupExpression>
<groupHeader>
<band/>
</groupHeader>
<groupFooter>
<band/>
</groupFooter>
</group>
<group name="jantina">
<groupExpression><![CDATA[$F{jantina}]]></groupExpression>
</group>
<background>
<band splitType="Stretch"/>
</background>
<title>
<band height="48" splitType="Stretch">
<staticText>
<reportElement x="237" y="10" width="100" height="20"/>
<textElement>
<font fontName="Arial" size="12"/>
</textElement>
<text><![CDATA[Penyata bulanan]]></text>
</staticText>
</band>
</title>
<pageHeader>
<band splitType="Stretch"/>
</pageHeader>
<columnHeader>
<band height="20" splitType="Stretch">
<staticText>
<reportElement x="0" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<text><![CDATA[negeri]]></text>
</staticText>
<staticText>
<reportElement x="79" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<text><![CDATA[jantina]]></text>
</staticText>
<staticText>
<reportElement x="158" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<text><![CDATA[bilmale]]></text>
</staticText>
<staticText>
<reportElement x="237" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<text><![CDATA[jds]]></text>
</staticText>
<staticText>
<reportElement x="316" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<text><![CDATA[percent]]></text>
</staticText>
<staticText>
<reportElement x="395" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<text><![CDATA[p_jdk]]></text>
</staticText>
<staticText>
<reportElement x="474" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<text><![CDATA[countstate]]></text>
</staticText>
</band>
</columnHeader>
<detail>
<band height="20" splitType="Stretch">
<textField>
<reportElement x="0" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<textFieldExpression class="java.lang.String"><![CDATA[$F{negeri}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="79" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<textFieldExpression class="java.lang.String"><![CDATA[$F{jantina}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="158" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{bilmale}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="237" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{jds}]]></textFieldExpression>
</textField>
<textField>
<reportElement isPrintRepeatedValues="false" x="316" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{percent}]]></textFieldExpression>
</textField>
<textField>
<reportElement isPrintRepeatedValues="false" x="395" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<textFieldExpression class="java.math.BigDecimal"><![CDATA[$F{p_jdk}]]></textFieldExpression>
</textField>
<textField>
<reportElement isPrintRepeatedValues="false" x="474" y="0" width="79" height="20"/>
<textElement textAlignment="Center">
<font fontName="Arial"/>
</textElement>
<textFieldExpression class="java.lang.Long"><![CDATA[$F{countstate}]]></textFieldExpression>
</textField>
</band>
</detail>
<columnFooter>
<band splitType="Stretch"/>
</columnFooter>
<pageFooter>
<band splitType="Stretch"/>
</pageFooter>
<summary>
<band splitType="Stretch"/>
</summary>
</jasperReport>

The answer is i create the group and put this formula in
"Print When Expression" into field. That is new Boolean($V{negeri_COUNT}.intValue()==1)
and i uncheck "Print Repeated values "

Related

Why is my expression off by 1 record?

I have a report that i am making using iReport and I have an equation that is helping me find duplicate Estimated Shipping variables and make the initial number stay the same but the ones displayed after it appear as 0. I want this because the report shows the changes made to the Sales Order but I dont want the report showing that the person was charged the initial Estimated Shipping ammount- every time.
The equation I am using to find the duplicates is
$V{SOID_Count}<=1?$F{SOITEM_UNITPRICE}:0
This works but if you notice in this picture the numbers are behind by one.
It is subtracting the Estimated Shipping amount that was above it- from the current Actual Shipping amount that you are on.
So how can I alter my counter equation to fix this?
Thank you for any help!
This is my XML
<?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="ShippingPriceDifference" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="97636279-f825-4b72-b9f8-8ce9740dce34">
<property name="ireport.zoom" value="1.5"/>
<property name="ireport.x" value="0"/>
<property name="ireport.y" value="0"/>
<parameter name="To" class="java.util.Date">
<parameterDescription><![CDATA[asdf]]></parameterDescription>
</parameter>
<parameter name="From" class="java.util.Date"/>
<queryString>
<![CDATA[SELECT
CUSTOMER."NAME" AS CUSTOMER_NAME,
SO."NUM" AS SO_NUM,
COMPANY."NAME" AS COMPANY_NAME,
SHIPCARTON."FREIGHTAMOUNT" AS SHIPCARTON_FREIGHTAMOUNT,
SHIP."SOID" AS SHIP_SOID,
SOITEM."UNITPRICE" AS SOITEM_UNITPRICE,
PRODUCT."PARTID" AS PRODUCT_PARTID,
SHIP."DATESHIPPED" AS SHIP_DATESHIPPED,
SOITEM."SOID" AS SOITEM_SOID
FROM
"CUSTOMER" CUSTOMER INNER JOIN "SO" SO ON CUSTOMER."ID" = SO."CUSTOMERID"
INNER JOIN "SHIP" SHIP ON SO."ID" = SHIP."SOID"
INNER JOIN "SOITEM" SOITEM ON SO."ID" = SOITEM."SOID"
INNER JOIN "PRODUCT" PRODUCT ON SOITEM."PRODUCTID" = PRODUCT."ID"
INNER JOIN "SHIPCARTON" SHIPCARTON ON SHIP."ID" = SHIPCARTON."SHIPID",
"COMPANY" COMPANY
WHERE
PRODUCT."PARTID" = 947
AND SHIP."DATESHIPPED" BETWEEN $P{From} AND $P{To}
AND SHIPCARTON."FREIGHTAMOUNT" != 0
ORDER BY
2 ASC]]>
</queryString>
<field name="CUSTOMER_NAME" class="java.lang.String"/>
<field name="SO_NUM" class="java.lang.String"/>
<field name="COMPANY_NAME" class="java.lang.String"/>
<field name="SHIPCARTON_FREIGHTAMOUNT" class="java.lang.Double"/>
<field name="SHIP_SOID" class="java.lang.Integer"/>
<field name="SOITEM_UNITPRICE" class="java.lang.Double"/>
<field name="PRODUCT_PARTID" class="java.lang.Integer"/>
<field name="SHIP_DATESHIPPED" class="java.sql.Timestamp"/>
<field name="SOITEM_SOID" class="java.lang.Integer"/>
<variable name="shipPriceDif" class="java.lang.Double">
<variableExpression><![CDATA[($F{SHIPCARTON_FREIGHTAMOUNT})- ($V{estimatedShipping})]]></variableExpression>
</variable>
<variable name="totalShipPriceDif" class="java.lang.Double" calculation="Sum">
<variableExpression><![CDATA[$V{shipPriceDif}]]></variableExpression>
</variable>
<variable name="SOID_Count" class="java.lang.Integer" resetType="Group" resetGroup="SOID" calculation="Count">
<variableExpression><![CDATA[$F{SOITEM_SOID}]]></variableExpression>
</variable>
<variable name="estimatedShipping" class="java.lang.Double">
<variableExpression><![CDATA[$V{SOID_Count}<=1?$F{SOITEM_UNITPRICE}:0]]> </variableExpression>
</variable>
<group name="SOID">
<groupExpression><![CDATA[$F{SOITEM_SOID}]]></groupExpression>
</group>
<background>
<band splitType="Stretch"/>
</background>
<title>
<band height="27" splitType="Stretch">
<textField>
<reportElement x="0" y="0" width="555" height="25" uuid="64a1704a-b221-48a4-8186-1b855ead5acf"/>
<textElement textAlignment="Center">
<font fontName="SansSerif" size="16" isBold="true"/>
</textElement>
<textFieldExpression><![CDATA[$F{COMPANY_NAME}]]></textFieldExpression>
</textField>
</band>
</title>
<pageHeader>
<band height="59" splitType="Stretch">
<staticText>
<reportElement x="0" y="0" width="555" height="25" uuid="e20cae54-5d75-4e81-800c-55390d1ec465"/>
<textElement textAlignment="Center">
<font fontName="SansSerif" size="14"/>
</textElement>
<text><![CDATA[Shipping Price Difference ]]></text>
</staticText>
<staticText>
<reportElement x="0" y="25" width="167" height="20" uuid="41be06d8-8fdf-4e3b-b526-1aea092ea734"/>
<textElement textAlignment="Right">
<font fontName="SansSerif" size="14" isBold="false"/>
</textElement>
<text><![CDATA[Date Range:]]></text>
</staticText>
<staticText>
<reportElement x="267" y="25" width="20" height="20" uuid="a402544b-73b3-4132-8161-be4c202e9b14"/>
<textElement textAlignment="Center">
<font fontName="SansSerif" size="14" isBold="false"/>
</textElement>
<text><![CDATA[-]]></text>
</staticText>
<textField>
<reportElement x="287" y="25" width="100" height="20" uuid="85e7fe2b-8149-4b18-8410-16b026cdb0f3"/>
<textElement verticalAlignment="Middle">
<font fontName="SansSerif" size="14"/>
</textElement>
<textFieldExpression><![CDATA[$P{To}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="167" y="25" width="100" height="20" uuid="ea618bea-9201-4eba-abff-cfdc891ac76f"/>
<textElement textAlignment="Right" verticalAlignment="Middle">
<font fontName="SansSerif" size="14"/>
</textElement>
<textFieldExpression><![CDATA[$P{From}]]></textFieldExpression>
</textField>
</band>
</pageHeader>
<columnHeader>
<band height="21" splitType="Stretch">
<staticText>
<reportElement x="0" y="0" width="140" height="20" uuid="82883a63-752d-4265-8158-a5129b617b7d"/>
<textElement>
<font size="12" isBold="true"/>
</textElement>
<text><![CDATA[Customer Name]]></text>
</staticText>
<staticText>
<reportElement x="140" y="0" width="75" height="20" uuid="2d302854-c68c-4e5a-b94b-900c88937b9d"/>
<textElement textAlignment="Center">
<font size="12" isBold="true"/>
</textElement>
<text><![CDATA[SO #]]></text>
</staticText>
<staticText>
<reportElement x="455" y="0" width="100" height="20" uuid="50c6ba0f-a5df-4aa3-8a47-282271055053"/>
<textElement textAlignment="Center">
<font size="12" isBold="true"/>
</textElement>
<text><![CDATA[Difference]]></text>
</staticText>
<line>
<reportElement x="0" y="19" width="555" height="1" uuid="be790d1c-d6d6-4169-b743-a98654c025e9"/>
</line>
<staticText>
<reportElement x="215" y="0" width="120" height="20" uuid="ffbe1333-86b8-435f-b914-46bb1c747683"/>
<textElement textAlignment="Center">
<font size="12" isBold="true"/>
</textElement>
<text><![CDATA[Estimated Shipping]]></text>
</staticText>
<staticText>
<reportElement x="335" y="0" width="120" height="20" uuid="3f683f6b-19f6-49dd-9ee1-787b216aaa2f"/>
<textElement textAlignment="Center">
<font size="12" isBold="true"/>
</textElement>
<text><![CDATA[Actual Shipping]]></text>
</staticText>
</band>
</columnHeader>
<detail>
<band height="21" splitType="Stretch">
<textField isBlankWhenNull="true">
<reportElement x="0" y="0" width="140" height="20" isRemoveLineWhenBlank="true" uuid="fdd69c30-9da5-4bd2-a7b8-44a506e2d7ff"/>
<textFieldExpression><![CDATA[$F{CUSTOMER_NAME}]]></textFieldExpression>
</textField>
<textField isBlankWhenNull="true" hyperlinkType="Reference">
<reportElement x="140" y="0" width="75" height="20" isRemoveLineWhenBlank="true" forecolor="#000099" uuid="19db6cb8-af37-46e6-9227-f1b55fc49f22"/>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{SO_NUM}]]></textFieldExpression>
<anchorNameExpression><![CDATA["SONum"]]></anchorNameExpression>
<hyperlinkReferenceExpression><![CDATA[$F{SO_NUM}]]></hyperlinkReferenceExpression>
</textField>
<textField pattern="#,##0.00" isBlankWhenNull="true">
<reportElement x="335" y="0" width="120" height="20" isRemoveLineWhenBlank="true" uuid="006475e5-d36f-4482-97cf-2c2eda2d5a66"/>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{SHIPCARTON_FREIGHTAMOUNT}]]></textFieldExpression>
</textField>
<textField pattern="#,##0.00" isBlankWhenNull="true">
<reportElement x="215" y="0" width="120" height="20" isRemoveLineWhenBlank="true" uuid="376d9c76-1d96-48ea-ac4a-40770ba28867"/>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$V{estimatedShipping}]]></textFieldExpression>
</textField>
<textField pattern="#,##0.00;-#,##0.00" isBlankWhenNull="true">
<reportElement x="455" y="0" width="100" height="20" isRemoveLineWhenBlank="true" uuid="c236c087-e6f4-4de6-a3d6-8abb8b798346"/>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$V{shipPriceDif}]]></textFieldExpression>
</textField>
</band>
</detail>
<pageFooter>
<band height="22" splitType="Stretch">
<textField>
<reportElement x="435" y="0" width="80" height="20" uuid="64e6c2aa-58eb-4994-83c3-16cb70197fef"/>
<textElement textAlignment="Right"/>
<textFieldExpression><![CDATA["Page "+$V{PAGE_NUMBER}+" of"]]></textFieldExpression>
</textField>
<textField evaluationTime="Report">
<reportElement x="515" y="0" width="40" height="20" uuid="09e2e08b-c9b1-4a5b-95fd-1c0a0dba17a2"/>
<textFieldExpression><![CDATA[" " + $V{PAGE_NUMBER}]]></textFieldExpression>
</textField>
</band>
</pageFooter>
<summary>
<band height="22" splitType="Stretch">
<textField pattern="#,##0.00;-#,##0.00">
<reportElement x="150" y="1" width="75" height="20" uuid="8ab3526d-e89e-4043-86dd-52d89a2b7b21"/>
<textElement verticalAlignment="Top">
<font size="12" isBold="true"/>
</textElement>
<textFieldExpression><![CDATA[$V{totalShipPriceDif}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="140" y="1" width="10" height="20" uuid="110043fb-4dde-414e-b07f-f79cbb8839ab"/>
<textElement textAlignment="Right">
<font size="12" isBold="true"/>
</textElement>
<text><![CDATA[$]]></text>
</staticText>
<line>
<reportElement x="0" y="0" width="555" height="1" uuid="e81602ee-7eab-43f3-90c1-cf69086623a9"/>
</line>
<staticText>
<reportElement x="0" y="1" width="140" height="20" uuid="095559e8-33e4-4a1a-9537-f8dff2b533d6"/>
<textElement>
<font size="12" isBold="true"/>
</textElement>
<text><![CDATA[Total Cost Difference :]]></text>
</staticText>
</band>
</summary>
</jasperReport>
Your problem is that the $V{estimatedShipping} is evaluated after your variable $V{shipPriceDif} since its after in your variable definition, or move it above or dump it...
Just calculate the Difference in the textField
<textField pattern="#,##0.00;-#,##0.00" isBlankWhenNull="true">
<reportElement x="455" y="0" width="100" height="20" isRemoveLineWhenBlank="true" uuid="c236c087-e6f4-4de6-a3d6-8abb8b798346"/>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$V{estimatedShipping}.doubleValue()-$F{SHIPCARTON_FREIGHTAMOUNT}.doubleValue()]]></textFieldExpression>
</textField>
The output of this would be:
+-------+-----------+--------+------------+
| SO# | Estimated | Actual | Difference |
+-------+-----------+--------+------------+
| 46137 | 700 | 58,38 | 641,62 |
| 46137 | 0 | 57,12 | -57.12 |
| 46137 | 0 | 28,29 | -28,29 |
| 46148 | 0,85 | 267,32 | -266,47 |
+-------+-----------+--------+------------+

How to break the single Line chart into next pages

Can you please suggest the code for getting new pages.
How to break the single Line chart into next pages with JasperReports 5.0
Here the code i attached for more details.
<?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="SystemSummary" language="groovy" pageWidth="842" pageHeight="595" orientation="Landscape" columnWidth="802" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="bd0eaa3b-093e-4699-83ef-75015530229d">
<parameter name="whereClause" class="java.lang.String"/>
<parameter name="bankLogo" class="java.lang.String"/>
<parameter name="bankName" class="java.lang.String"/>
<parameter name="fromDate" class="java.util.Date">
<parameterDescription><![CDATA[]]></parameterDescription>
</parameter>
<parameter name="toDate" class="java.util.Date"/>
<parameter name="noData" class="java.lang.String"/>
<parameter name="userId" class="java.lang.String"/>
<queryString>
<![CDATA[select avg(jbase_user) as jbaseAvg,AVG(t24_user) as t24Avg,to_char(load_time, 'dd.Mon.yy HH24') as period
from tmc_system_summary group by (to_char(load_time, 'dd.Mon.yy HH24'))]]>
</queryString>
<field name="jbaseavg" class="java.math.BigDecimal"/>
<field name="t24avg" class="java.math.BigDecimal"/>
<field name="period" class="java.lang.String"/>
<background>
<band splitType="Stretch"/>
</background>
<title>
<band height="2" splitType="Stretch"/>
</title>
<pageHeader>
<band height="57" splitType="Stretch">
<staticText>
<reportElement x="300" y="25" width="235" height="15" uuid="164831c1-9eff-4cf2-8706-331d28fdf431"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial" size="12" isBold="true" pdfFontName="Helvetica-Bold"/>
</textElement>
<text><![CDATA[System Summary Report]]></text>
</staticText>
<textField pattern="dd/MM/yyyy">
<reportElement x="735" y="2" width="55" height="17" uuid="306ddad6-2b80-4abb-9893-859c59c8ede5"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial"/>
</textElement>
<textFieldExpression><![CDATA[new java.util.Date()]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="700" y="2" width="30" height="17" uuid="c6fdbff7-45a5-464e-bcbf-d550b174452f"/>
<textElement textAlignment="Right" verticalAlignment="Middle">
<font fontName="Arial"/>
</textElement>
<text><![CDATA[Date:]]></text>
</staticText>
<image>
<reportElement x="20" y="3" width="130" height="30" uuid="513d2931-a2c7-4e54-bb86-188737502cae"/>
<imageExpression><![CDATA[$P{bankLogo}]]></imageExpression>
</image>
<staticText>
<reportElement x="20" y="40" width="58" height="14" uuid="5bd47ff1-6b81-428a-b7fd-50e777f70a22"/>
<textElement textAlignment="Center" verticalAlignment="Middle"/>
<text><![CDATA[From Date:]]></text>
</staticText>
<staticText>
<reportElement x="160" y="40" width="58" height="14" uuid="a7605d9e-c0d1-4a31-8230-c73db35766d4"/>
<textElement textAlignment="Center" verticalAlignment="Middle"/>
<text><![CDATA[To Date:]]></text>
</staticText>
<textField pattern="dd/MM/yyyy">
<reportElement x="80" y="40" width="70" height="14" uuid="faa13401-da98-4f06-ab43-5a1722d073f7"/>
<textFieldExpression><![CDATA[$P{fromDate} != null ? $P{fromDate} :" "]]></textFieldExpression>
</textField>
<textField pattern="dd/MM/yyyy">
<reportElement x="215" y="40" width="70" height="13" uuid="01fcdb71-820f-4ef1-9913-6ddcf36be2dc"/>
<textFieldExpression><![CDATA[$P{toDate} != null ? $P{toDate} : " "]]></textFieldExpression>
</textField>
<textField>
<reportElement x="300" y="5" width="235" height="17" uuid="7eec4f6f-5bfd-4bb0-8888-8cad8d9d84ad"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial" size="14" isBold="true" pdfFontName="Helvetica-Bold"/>
</textElement>
<textFieldExpression><![CDATA[$P{bankName}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="700" y="22" width="30" height="15" uuid="08ba273e-733d-4652-9f7a-83a51f7d78ca"/>
<textElement textAlignment="Right"/>
<text><![CDATA[By:]]></text>
</staticText>
<textField>
<reportElement x="735" y="22" width="55" height="15" uuid="261308a5-7cef-42f8-8880-9d2c9cc5d5ae"/>
<textFieldExpression><![CDATA[$P{userId}]]></textFieldExpression>
</textField>
<line>
<reportElement x="10" y="54" width="780" height="1" uuid="062e928b-20d3-4345-a97e-b16eff81d254"/>
</line>
</band>
</pageHeader>
<columnHeader>
<band height="3" splitType="Stretch"/>
</columnHeader>
<detail>
<band height="3" splitType="Stretch"/>
</detail>
<columnFooter>
<band height="2" splitType="Stretch"/>
</columnFooter>
<pageFooter>
<band height="27">
<textField>
<reportElement x="397" y="5" width="65" height="20" uuid="e40834ac-921f-4171-a500-ebfc9a43124a"/>
<textElement textAlignment="Left" verticalAlignment="Middle">
<font fontName="Arial" size="10"/>
</textElement>
<textFieldExpression><![CDATA["Page " + $V{PAGE_NUMBER}]]></textFieldExpression>
</textField>
</band>
</pageFooter>
<summary>
<band height="273" splitType="Stretch">
<lineChart>
<chart>
<reportElement x..
i am using line chart, how can i split the graph and keeping all the data next pages
maybe you can try to change the "splitType" of summary band to "Immediate"

x axis value displayed in line chart

I have Line chart, in x axis i should display date in string format in full format, but i cant display when more no of values in x axis, for that i decided to display x axis values in vertical manner instead of horizontal , please suggest me. for ref attached image..
<?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="sampl1" language="groovy" pageWidth="842" pageHeight="595" orientation="Landscape" columnWidth="802" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="431d18d3-722a-4aaf-8207-da8bb0ea2fdd">
<property name="ireport.zoom" value="1.0"/>
<property name="ireport.x" value="0"/>
<property name="ireport.y" value="51"/>
<parameter name="whereClause" class="java.lang.String"/>
<parameter name="bankLogo" class="java.lang.String"/>
<parameter name="bankName" class="java.lang.String"/>
<parameter name="fromDate" class="java.util.Date">
<parameterDescription><![CDATA[]]></parameterDescription>
</parameter>
<parameter name="toDate" class="java.util.Date"/>
<parameter name="noData" class="java.lang.String"/>
<parameter name="userId" class="java.lang.String"/>
<queryString>
<![CDATA[select avg(jbase_user) as jbaseAvg,AVG(t24_user) as t24Avg,to_char(load_time, 'dd.Mon.yy HH24') as period
from tmc_system_summary group by (to_char(load_time, 'dd.Mon.yy HH24'))]]>
</queryString>
<field name="jbaseavg" class="java.math.BigDecimal"/>
<field name="t24avg" class="java.math.BigDecimal"/>
<field name="period" class="java.lang.String"/>
<background>
<band splitType="Stretch"/>
</background>
<title>
<band height="30" splitType="Stretch"/>
</title>
<pageHeader>
<band height="67" splitType="Stretch">
<staticText>
<reportElement x="300" y="22" width="235" height="15" uuid="164831c1-9eff-4cf2-8706-331d28fdf431"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial" size="12" isBold="true" pdfFontName="Helvetica-Bold"/>
</textElement>
<text><![CDATA[ System Summary Report]]></text>
</staticText>
<image>
<reportElement x="12" y="3" width="161" height="30" uuid="513d2931-a2c7-4e54-bb86-188737502cae"/>
<imageExpression><![CDATA[$P{bankLogo}]]></imageExpression>
</image>
<textField pattern="dd/MM/yyyy">
<reportElement x="735" y="2" width="55" height="17" uuid="306ddad6-2b80-4abb-9893-859c59c8ede5"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial"/>
</textElement>
<textFieldExpression><![CDATA[new java.util.Date()]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="700" y="2" width="30" height="17" uuid="c6fdbff7-45a5-464e-bcbf-d550b174452f"/>
<textElement textAlignment="Right" verticalAlignment="Middle">
<font fontName="Arial"/>
</textElement>
<text><![CDATA[Date:]]></text>
</staticText>
<staticText>
<reportElement x="20" y="40" width="58" height="14" uuid="5bd47ff1-6b81-428a-b7fd-50e777f70a22"/>
<textElement textAlignment="Center" verticalAlignment="Middle"/>
<text><![CDATA[From Date:]]></text>
</staticText>
<staticText>
<reportElement x="160" y="40" width="58" height="14" uuid="a7605d9e-c0d1-4a31-8230-c73db35766d4"/>
<textElement textAlignment="Center" verticalAlignment="Middle"/>
<text><![CDATA[To Date:]]></text>
</staticText>
<textField pattern="dd/MM/yyyy">
<reportElement x="80" y="40" width="70" height="14" uuid="faa13401-da98-4f06-ab43-5a1722d073f7"/>
<textFieldExpression><![CDATA[$P{fromDate} != null ? $P{fromDate} :" "]]></textFieldExpression>
</textField>
<textField pattern="dd/MM/yyyy">
<reportElement x="215" y="40" width="70" height="13" uuid="01fcdb71-820f-4ef1-9913-6ddcf36be2dc"/>
<textFieldExpression><![CDATA[$P{toDate} != null ? $P{toDate} : " "]]></textFieldExpression>
</textField>
<textField>
<reportElement x="300" y="2" width="235" height="17" uuid="7eec4f6f-5bfd-4bb0-8888-8cad8d9d84ad"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial" size="14" isBold="true" pdfFontName="Helvetica-Bold"/>
</textElement>
<textFieldExpression><![CDATA[$P{bankName}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="700" y="22" width="30" height="15" uuid="08ba273e-733d-4652-9f7a-83a51f7d78ca"/>
<textElement textAlignment="Right"/>
<text><![CDATA[By:]]></text>
</staticText>
<textField>
<reportElement x="735" y="22" width="55" height="15" uuid="261308a5-7cef-42f8-8880-9d2c9cc5d5ae"/>
<textFieldExpression><![CDATA[$P{userId}]]></textFieldExpression>
</textField>
<line>
<reportElement x="0" y="54" width="802" height="1" uuid="e17b6ea4-40fd-40ad-861f-a300f926d0e4"/>
</line>
</band>
</pageHeader>
<columnHeader>
<band splitType="Stretch"/>
![enter image description here][1] </columnHeader>
<columnFooter>
<band height="17" splitType="Stretch"/>
</columnFooter>
<pageFooter>
<band height="20" splitType="Stretch">
<textField>
<reportElement x="546" y="1" width="70" height="19" uuid="eeafb0de-dddb-4c9a-8a1d-942b65bf0a7f"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial" size="10"/>
</textElement>
<textFieldExpression><![CDATA["Page " + $V{PAGE_NUMBER}]]></textFieldExpression>
</textField>
</band>
</pageFooter>
<summary>
<band height="392" splitType="Stretch">
<lineChart>
<chart>
<reportElement x="12" y="18" width="779" height="355" uuid="f696d665..
By this you can display the x axis value in vertical ( topDown)
<categoryAxisFormat labelRotation="90.0">
it will work.

Formatting layout of Jasper report through iReport, to remove space between bands

I have the below report, developed using iReport 3.0 (we have to use this version because of system constraints). But no matter what I do, I can not get rid of the white space between the Page Header (addresses) and the Column Header.
JRXML:
<?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="customisation_summary" pageWidth="595" pageHeight="700" columnWidth="535" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" isFloatColumnFooter="true">
<style name="alternateStyle" isDefault="false" backcolor="#FFFFFF" fontName="Arial">
<conditionalStyle>
<conditionExpression><![CDATA[new Boolean($V{REPORT_COUNT}.intValue() % 2 == 0)]]></conditionExpression>
<style isDefault="false" style="alternateStyle" backcolor="#F7F7F7"/>
</conditionalStyle>
</style>
<parameter name="orderId" class="java.lang.String">
<defaultValueExpression><![CDATA[new Integer(0).toString()]]></defaultValueExpression>
</parameter>
<parameter name="REPORT_IMG_DIR" class="java.lang.String" isForPrompting="false">
<defaultValueExpression><![CDATA["C:\\kukri\\workspaces\\sts_3_0_0\\clubshop\\clubshop\\src\\main\\webapp\\jasper\\images\\"]]></defaultValueExpression>
</parameter>
<parameter name="SUBREPORT_DIR" class="java.lang.String" isForPrompting="false">
<defaultValueExpression><![CDATA["C:\\kukri\\workspaces\\sts_3_0_0\\clubshop\\clubshop\\src\\main\\webapp\\jasper\\"]]></defaultValueExpression>
</parameter>
<queryString>
<![CDATA[SELECT so.customer_id, so.order_date, so.order_ref, p.product_code, p.colour_code, p.name, SUM(soi.quantity) AS quantity, sz.size, '-' AS uom, '-' AS location, scc.unit_charge, SUM(soi.quantity * scc.unit_charge) total_charge
FROM sales_order AS so, sales_order_item AS soi, product AS p, stock AS st, size AS sz, stock_currency_charge AS scc
WHERE so.id = soi.order_id
AND soi.stock_id = st.id
AND st.product_id = p.id
AND st.id = scc.stock_id
AND st.size_id = sz.id
AND so.currency = scc.currency_code
AND so.id = '$P!{orderId}'
GROUP BY st.id
ORDER BY p.name, sz.display_seq]]>
</queryString>
<field name="customer_id" class="java.lang.String">
<fieldDescription><![CDATA[]]></fieldDescription>
</field>
<field name="order_date" class="java.sql.Timestamp">
<fieldDescription><![CDATA[]]></fieldDescription>
</field>
<field name="order_ref" class="java.lang.String">
<fieldDescription><![CDATA[]]></fieldDescription>
</field>
<field name="product_code" class="java.lang.String">
<fieldDescription><![CDATA[]]></fieldDescription>
</field>
<field name="colour_code" class="java.lang.String">
<fieldDescription><![CDATA[]]></fieldDescription>
</field>
<field name="name" class="java.lang.String">
<fieldDescription><![CDATA[]]></fieldDescription>
</field>
<field name="quantity" class="java.lang.Integer">
<fieldDescription><![CDATA[]]></fieldDescription>
</field>
<field name="size" class="java.lang.String">
<fieldDescription><![CDATA[]]></fieldDescription>
</field>
<field name="uom" class="java.lang.String">
<fieldDescription><![CDATA[]]></fieldDescription>
</field>
<field name="location" class="java.lang.String">
<fieldDescription><![CDATA[]]></fieldDescription>
</field>
<field name="unit_charge" class="java.math.BigDecimal">
<fieldDescription><![CDATA[]]></fieldDescription>
</field>
<field name="total_charge" class="java.math.BigDecimal">
<fieldDescription><![CDATA[]]></fieldDescription>
</field>
<title>
<band height="72" isSplitAllowed="false">
<image onErrorType="Icon">
<reportElement key="image-4" x="-1" y="0" width="555" height="71"/>
<imageExpression class="java.lang.String"><![CDATA[$P{REPORT_IMG_DIR} + "//Top_Image.png"]]></imageExpression>
</image>
<staticText>
<reportElement x="307" y="51" width="247" height="20"/>
<textElement textAlignment="Right">
<font size="14"/>
</textElement>
<text><![CDATA[Order Customisation Pick Sheet]]></text>
</staticText>
</band>
</title>
<pageHeader>
<band height="45">
<staticText>
<reportElement x="399" y="2" width="62" height="18"/>
<textElement textAlignment="Right" verticalAlignment="Middle">
<font isBold="true"/>
</textElement>
<text><![CDATA[Order Ref: ]]></text>
</staticText>
<textField>
<reportElement x="464" y="20" width="92" height="20"/>
<textElement textAlignment="Right" verticalAlignment="Middle"/>
<textFieldExpression class="java.util.Date"><![CDATA[$F{order_date}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="464" y="1" width="93" height="20"/>
<textElement textAlignment="Right" verticalAlignment="Middle"/>
<textFieldExpression class="java.lang.String"><![CDATA[$F{order_ref}]]></textFieldExpression>
</textField>
<staticText>
<reportElement x="399" y="20" width="62" height="20"/>
<textElement textAlignment="Right" verticalAlignment="Middle">
<font size="10" isBold="true"/>
</textElement>
<text><![CDATA[Order Date: ]]></text>
</staticText>
<subreport>
<reportElement x="179" y="1" width="175" height="40"/>
<subreportParameter name="customer_id">
<subreportParameterExpression><![CDATA[$F{customer_id}]]></subreportParameterExpression>
</subreportParameter>
<connectionExpression><![CDATA[$P{REPORT_CONNECTION}]]></connectionExpression>
<subreportExpression class="java.lang.String"><![CDATA[$P{SUBREPORT_DIR} + "customisation_jobsheet_summary_invaddy.jasper"]]></subreportExpression>
</subreport>
<subreport>
<reportElement x="0" y="0" width="175" height="40"/>
<subreportParameter name="customer_id">
<subreportParameterExpression><![CDATA[$F{customer_id}]]></subreportParameterExpression>
</subreportParameter>
<connectionExpression><![CDATA[$P{REPORT_CONNECTION}]]></connectionExpression>
<subreportExpression class="java.lang.String"><![CDATA[$P{SUBREPORT_DIR} + "customisation_jobsheet_summary_del_addy.jasper"]]></subreportExpression>
</subreport>
</band>
</pageHeader>
<columnHeader>
<band height="20">
<staticText>
<reportElement mode="Opaque" x="23" y="1" width="79" height="18" backcolor="#CCCCCC"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font size="8" isBold="true"/>
</textElement>
<text><![CDATA[Product Code]]></text>
</staticText>
<staticText>
<reportElement mode="Opaque" x="463" y="1" width="39" height="18" backcolor="#CCCCCC"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font size="8" isBold="true"/>
</textElement>
<text><![CDATA[UOM]]></text>
</staticText>
<staticText>
<reportElement mode="Opaque" x="178" y="1" width="231" height="18" backcolor="#CCCCCC"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font size="8" isBold="true"/>
</textElement>
<text><![CDATA[Product ]]></text>
</staticText>
<staticText>
<reportElement mode="Opaque" x="102" y="1" width="76" height="18" backcolor="#CCCCCC"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font size="8" isBold="true"/>
</textElement>
<text><![CDATA[Colour]]></text>
</staticText>
<staticText>
<reportElement mode="Opaque" x="409" y="1" width="26" height="18" backcolor="#CCCCCC"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font size="8" isBold="true"/>
</textElement>
<text><![CDATA[Size]]></text>
</staticText>
<staticText>
<reportElement mode="Opaque" x="435" y="1" width="28" height="18" backcolor="#CCCCCC"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font size="8" isBold="true"/>
</textElement>
<text><![CDATA[QTY]]></text>
</staticText>
<staticText>
<reportElement mode="Opaque" x="501" y="1" width="55" height="18" backcolor="#CCCCCC"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font size="8" isBold="true"/>
</textElement>
<text><![CDATA[Location]]></text>
</staticText>
<staticText>
<reportElement mode="Opaque" x="2" y="1" width="21" height="18" backcolor="#CCCCCC"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font size="8" isBold="true"/>
</textElement>
<text><![CDATA[#]]></text>
</staticText>
</band>
</columnHeader>
<detail>
<band height="19">
<textField>
<reportElement style="alternateStyle" isPrintRepeatedValues="false" x="21" y="1" width="79" height="18"/>
<textElement textAlignment="Center"/>
<textFieldExpression class="java.lang.String"><![CDATA[$F{product_code}]]></textFieldExpression>
</textField>
<textField>
<reportElement style="alternateStyle" isPrintRepeatedValues="false" x="176" y="1" width="231" height="18"/>
<textElement/>
<textFieldExpression class="java.lang.String"><![CDATA[$F{name}]]></textFieldExpression>
</textField>
<textField>
<reportElement style="alternateStyle" isPrintRepeatedValues="false" x="100" y="1" width="76" height="18"/>
<textElement textAlignment="Center"/>
<textFieldExpression class="java.lang.String"><![CDATA[$F{colour_code}]]></textFieldExpression>
</textField>
<textField>
<reportElement style="alternateStyle" x="433" y="1" width="28" height="18"/>
<textElement textAlignment="Center"/>
<textFieldExpression class="java.lang.Integer"><![CDATA[$F{quantity}]]></textFieldExpression>
</textField>
<textField>
<reportElement style="alternateStyle" x="461" y="1" width="39" height="18"/>
<textElement textAlignment="Center"/>
<textFieldExpression class="java.lang.String"><![CDATA[$F{uom}]]></textFieldExpression>
</textField>
<textField>
<reportElement style="alternateStyle" x="499" y="1" width="55" height="18"/>
<textElement textAlignment="Center"/>
<textFieldExpression class="java.lang.String"><![CDATA[$F{location}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="0" y="1" width="21" height="18"/>
<textElement textAlignment="Center"/>
<textFieldExpression class="java.lang.Integer"><![CDATA[$V{REPORT_COUNT}]]></textFieldExpression>
</textField>
<textField>
<reportElement style="alternateStyle" x="407" y="1" width="26" height="18"/>
<textElement textAlignment="Center"/>
<textFieldExpression class="java.lang.String"><![CDATA[$F{size}]]></textFieldExpression>
</textField>
</band>
</detail>
<columnFooter>
<band height="50"/>
</columnFooter>
<summary>
<band height="80"/>
</summary>
</jasperReport>

Stretch with overflow Detail band not working as expected

I have a simple report. It has two bands title and detail.
In the Title I have a static text, in the Detail I have one textField.
The textField is set to stretchwithoverflow = "true". If I set the height for this field to fit one raw information, I get for the larger information one and a half rows. So one textField, in the textField I have 2 rows information, first row displayed correctly, second one - I can see a half height.
Can this be done? Expand only the rows that contain larger information and the larger information will fit well in the text field?
<?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="report7" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="15f9d2dd-21ce-41ec-bcb8-c1aca3a77e37">
<parameter name="EndDate" class="java.util.Date">
<defaultValueExpression><![CDATA[new java.util.Date()]]></defaultValueExpression>
</parameter>
<parameter name="Project" class="java.util.Collection"/>
<parameter name="Severity" class="java.util.Collection"/>
<parameter name="StartDate" class="java.util.Date">
<defaultValueExpression><![CDATA[new java.util.Date(112, 0, 01)]]></defaultValueExpression>
</parameter>
<parameter name="Project_Sets" class="java.util.Collection"/>
<queryString>
<![CDATA[some query]]>
</queryString>
<field name="crid" class="java.lang.String"/>
<field name="SEVER" class="java.lang.String"/>
<field name="product" class="java.lang.String"/>
<field name="state" class="java.lang.String"/>
<field name="status" class="java.lang.String"/>
<field name="submit_date" class="java.lang.String"/>
<field name="aging" class="java.lang.Long"/>
<title>
<band height="25" splitType="Stretch">
<staticText>
<reportElement uuid="63eef93a-7e8f-4c69-b9d6-4447fe90673d" x="0" y="0" width="555" height="25" forecolor="#3399FF"/>
<textElement textAlignment="Center">
<font size="16" isBold="true"/>
</textElement>
<text><![CDATA[Defects Aging]]></text>
</staticText>
</band>
</title>
<columnHeader>
<band height="32">
<rectangle>
<reportElement uuid="9a2288d4-87ce-4ee7-b04e-267a7ee0ea8b" x="0" y="0" width="555" height="32" backcolor="#99CC00"/>
</rectangle>
<staticText>
<reportElement uuid="9281aa7a-4bcc-4456-9f25-83c7b2360a01" x="0" y="0" width="79" height="32" forecolor="#FFFFFF"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial" size="12" isBold="true"/>
</textElement>
<text><![CDATA[CRID]]></text>
</staticText>
<staticText>
<reportElement uuid="cacda134-069c-43ae-abc1-76f5c865df41" x="79" y="0" width="79" height="32" forecolor="#FFFFFF"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial" size="12" isBold="true"/>
</textElement>
<text><![CDATA[Severity]]></text>
</staticText>
<staticText>
<reportElement uuid="d798786f-5ee0-4e76-8a35-2f908af6e92c" positionType="Float" x="158" y="0" width="79" height="32" forecolor="#FFFFFF"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial" size="12" isBold="true"/>
</textElement>
<text><![CDATA[Product]]></text>
</staticText>
<staticText>
<reportElement uuid="6be4792d-01a5-4d18-940d-90f40417c7ad" positionType="Float" x="237" y="0" width="79" height="32" forecolor="#FFFFFF"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial" size="12" isBold="true"/>
</textElement>
<text><![CDATA[State]]></text>
</staticText>
<staticText>
<reportElement uuid="fa447ca9-121c-43fb-a7bf-1b29ada93adf" positionType="Float" x="316" y="0" width="79" height="32" forecolor="#FFFFFF"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial" size="12" isBold="true"/>
</textElement>
<text><![CDATA[Status]]></text>
</staticText>
<staticText>
<reportElement uuid="b2d8f1db-871b-4e34-942f-b8c4a87a358b" positionType="Float" x="395" y="0" width="79" height="32" forecolor="#FFFFFF"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial" size="12" isBold="true"/>
</textElement>
<text><![CDATA[Submit Date]]></text>
</staticText>
<staticText>
<reportElement uuid="c3eddc7c-25ca-4e29-a01e-13e856b67d03" x="474" y="0" width="79" height="32" forecolor="#FFFFFF"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font fontName="Arial" size="12" isBold="true"/>
</textElement>
<text><![CDATA[Days]]></text>
</staticText>
</band>
</columnHeader>
<detail>
<band height="81" splitType="Stretch">
<elementGroup>
<textField isStretchWithOverflow="true">
<reportElement uuid="6422c6d3-40b9-4e38-8bb4-ded91c91ac17" stretchType="RelativeToBandHeight" x="158" y="0" width="79" height="39"/>
<textElement textAlignment="Left" verticalAlignment="Middle"/>
<textFieldExpression><![CDATA[$F{product}]]></textFieldExpression>
</textField>
</elementGroup>
</band>
</detail>
</jasperReport>
In the same band if there are more items and you want to have all same stretched. It has to be set to all of them to stretchType="RelativeToTallestObject" and isStretchWithOverflow="true".
<textField isStretchWithOverflow="true" pattern="###0">
<reportElement stretchType="RelativeToTallestObject" x="1576" y="0" width="91" height="20"/>
<textElement textAlignment="Center"/>
<textFieldExpression class="java.lang.Long"><![CDATA[$F{count_tohfa}]]></textFieldExpression>
</textField>
Report property: Add this
net.sf.jasperreports.text.save.line = true
net.sf.jasperreports.export.html.wrap.break.word = true
Source: Word Wrapping HTML versus PDF