Jump to content

balajicrb

Members
  • Posts

    7
  • Joined

  • Last visited

balajicrb's Achievements

Rookie

Rookie (2/14)

  • Week One Done
  • One Month Later
  • One Year In
  • First Post Rare
  • Conversation Starter Rare

Recent Badges

0

Reputation

  1. Hi All, The report is not reflected as in the database when I tried to use Mondrian connection. The JasperServer caches the snapshot of the schema getting referred and renders the same even after the record values in database is changed. How to avoid this cache issue..? Please help. Regards, Balaji C R B
  2. This thread can help you... http://www.jasperassistant.com/forum/topic/823/simple_subreport_example_using_several?p3 --Balaji CRB
  3. Hi, You can create two sub reports in a report and each sub report can take one JRResultDataSource to fill. -- Balaji C R B
  4. Hi Guys, I am using crosstab to generate report as below. Year Product Sales Profit Loss Printer 500 200 0 Paper 200 0 400 Disk 1000 100 0 Now the requirement is for each item in detail section (sales/Profit/loss) I have a flag set whether to show that or not. Assume if the flag is set to not show Profit, then report comes like: Year Product Sales Loss Printer 500 0 Paper 200 400 Disk 1000 0 I want to avoid this unncessary column space we are getting in the crosstab since profit is not shown. Please suggest on this. Regards, Balaji C R B
  5. Hi All, My report has many pages. Each page I will be showing something in Page Header band. Now only for the last page and in that last page's Page Header band I want to show/hide some additional info. So I need to identify whether a page is last page or not. Anyone have idea or solution regarding this, please reply . Regards, Balaji C R B
  6. Hi All, I am trying to design a Multi-Axis Chart having two line charts. Each line chart use separate subdataset to run. The datasource being used for each subdataset is JRBeanCollectionDataSource. I could able to get only one line chart which i added last(second chart). If I change the order (keeping the second chart added first and the first as second) I could get the first chart. But this time the second chart is not coming. Note: When i use query and supply connection object then i could get both the line charts properly. I don't know why if I supply distinct JRBeanCollectionDataSource for the subdataset, whichever the dataset being used for the first chart , it is not coming!!!! Please help me with this.... Regards, Balaji C R B Code:<?xml version="1.0" encoding="UTF-8" ?><!-- Created with iReport - A designer for JasperReports --><!DOCTYPE jasperReport PUBLIC "//JasperReports//DTD Report Design//EN" "http://jasperreports.sourceforge.net/dtds/jasperreport.dtd"><jasperReport name="try3_1" columnCount="1" printOrder="Vertical" orientation="Portrait" pageWidth="842" pageHeight="1200" columnWidth="782" columnSpacing="0" leftMargin="30" rightMargin="30" topMargin="20" bottomMargin="20" whenNoDataType="NoPages" isTitleNewPage="false" isSummaryNewPage="false"> <property name="ireport.scriptlethandling" value="0" /> <property name="ireport.encoding" value="UTF-8" /> <import value="java.util.*" /> <import value="net.sf.jasperreports.engine.*" /> <import value="net.sf.jasperreports.engine.data.*" /> <subDataset name="SubDataset1" > <parameter name="filterParam1" isForPrompting="true" class="java.lang.String"/> <queryString><![CDATA[select * from KFANDVALUE]]></queryString> <field name="comparison" class="java.lang.String"/> <field name="period" class="java.lang.String"/> <field name="time_density" class="java.lang.String"/> <field name="period_value" class="java.lang.String"/> <field name="entity_name" class="java.lang.String"/> <field name="result_value" class="java.lang.Double"/> <field name="budget_value" class="java.lang.Double"/> <filterExpression><![CDATA[new Boolean($F{comparison}.equalsIgnoreCase( $P{filterParam1}) )]]></filterExpression> </subDataset> <subDataset name="SubDataset2" > <parameter name="filterParam2" isForPrompting="true" class="java.lang.String"/> <queryString><![CDATA[select * from KFANDVALUE]]></queryString> <field name="comparison" class="java.lang.String"/> <field name="period" class="java.lang.String"/> <field name="time_density" class="java.lang.String"/> <field name="period_value" class="java.lang.String"/> <field name="entity_name" class="java.lang.String"/> <field name="result_value" class="java.lang.Double"/> <field name="budget_value" class="java.lang.Double"/> <filterExpression><![CDATA[new Boolean($F{comparison}.equalsIgnoreCase( $P{filterParam2}) )]]></filterExpression> </subDataset> <parameter name="subDataSet2DS" isForPrompting="false" class="net.sf.jasperreports.engine.JRDataSource"/> <parameter name="subDataSet1DS" isForPrompting="false" class="net.sf.jasperreports.engine.JRDataSource"/> <parameter name="filterParam1" isForPrompting="true" class="java.lang.String"/> <parameter name="filterParam2" isForPrompting="true" class="java.lang.String"/> <parameter name="dummyparam" isForPrompting="false" class="java.lang.String"/> <queryString><![CDATA[select * from KFANDVALUE]]></queryString> <field name="comparison" class="java.lang.String"/> <field name="period" class="java.lang.String"/> <field name="time_density" class="java.lang.String"/> <field name="period_value" class="java.lang.String"/> <field name="entity_name" class="java.lang.String"/> <field name="result_value" class="java.lang.Double"/> <field name="budget_value" class="java.lang.Double"/> <variable name="vcomp1" class="java.lang.String" resetType="Report" calculation="Lowest"> <variableExpression><![CDATA[$F{comparison}]]></variableExpression> </variable> <variable name="vcomp2" class="java.lang.String" resetType="Report" calculation="Highest"> <variableExpression><![CDATA[$F{comparison}]]></variableExpression> </variable> <group name="Comparison" > <groupExpression><![CDATA[$F{comparison}]]></groupExpression> <groupHeader> <band height="0" isSplitAllowed="true" > </band> </groupHeader> <groupFooter> <band height="0" isSplitAllowed="true" > </band> </groupFooter> </group> <background> <band height="0" isSplitAllowed="true" > </band> </background> <title> <band height="24" isSplitAllowed="true" > </band> </title> <pageHeader> <band height="0" isSplitAllowed="true" > </band> </pageHeader> <columnHeader> <band height="0" isSplitAllowed="true" > </band> </columnHeader> <detail> <band height="19" isSplitAllowed="true" > <textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None" hyperlinkTarget="Self" > <reportElement x="2" y="0" width="100" height="18" key="textField"/> <box></box> <textElement> <font/> </textElement> <textFieldExpression class="java.lang.String"><![CDATA[$F{comparison}]]></textFieldExpression> </textField> <textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None" hyperlinkTarget="Self" > <reportElement x="202" y="0" width="100" height="18" key="textField"/> <box></box> <textElement> <font/> </textElement> <textFieldExpression class="java.lang.String"><![CDATA[$F{period}]]></textFieldExpression> </textField> <textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None" hyperlinkTarget="Self" > <reportElement x="402" y="0" width="100" height="18" key="textField"/> <box></box> <textElement> <font/> </textElement> <textFieldExpression class="java.lang.String"><![CDATA[$F{period_value}]]></textFieldExpression> </textField> <textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None" hyperlinkTarget="Self" > <reportElement x="102" y="0" width="100" height="18" key="textField"/> <box></box> <textElement> <font/> </textElement> <textFieldExpression class="java.lang.String"><![CDATA[$F{entity_name}]]></textFieldExpression> </textField> <textField isStretchWithOverflow="false" pattern="##0.00" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None" hyperlinkTarget="Self" > <reportElement x="502" y="0" width="100" height="18" key="textField"/> <box></box> <textElement> <font/> </textElement> <textFieldExpression class="java.lang.Double"><![CDATA[$F{result_value}]]></textFieldExpression> </textField> <textField isStretchWithOverflow="false" pattern="##0.00" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None" hyperlinkTarget="Self" > <reportElement x="602" y="0" width="100" height="18" key="textField"/> <box></box> <textElement> <font/> </textElement> <textFieldExpression class="java.lang.Double"><![CDATA[$F{budget_value}]]></textFieldExpression> </textField> <textField isStretchWithOverflow="false" isBlankWhenNull="false" evaluationTime="Now" hyperlinkType="None" hyperlinkTarget="Self" > <reportElement x="302" y="0" width="100" height="18" key="textField"/> <box></box> <textElement> <font/> </textElement> <textFieldExpression class="java.lang.String"><![CDATA[$F{time_density}]]></textFieldExpression> </textField> </band> </detail> <columnFooter> <band height="0" isSplitAllowed="true" > </band> </columnFooter> <pageFooter> <band height="0" isSplitAllowed="true" > </band> </pageFooter> <summary> <band height="308" isSplitAllowed="true" > <multiAxisChart> <chart hyperlinkTarget="Self" > <reportElement x="21" y="21" width="504" height="276" key="element-1"/> <box></box> <chartLegend textColor="#000000" backgroundColor="#FFFFFF" > </chartLegend> </chart> <multiAxisPlot> <plot /> <axis > <lineChart> <chart hyperlinkTarget="Self" > <reportElement x="-80" y="-762" width="0" height="0" key="element-30"/> <box></box> <chartLegend textColor="#000000" backgroundColor="#FFFFFF" > </chartLegend> </chart> <categoryDataset> <dataset resetType="None" > <datasetRun subDataset="SubDataset1"> <datasetParameter name="filterParam1"> <datasetParameterExpression><![CDATA[$P{filterParam1}]]></datasetParameterExpression> </datasetParameter> <dataSourceExpression><![CDATA[$P{subDataSet1DS}]]></dataSourceExpression> </datasetRun> </dataset> <categorySeries> <seriesExpression><![CDATA[$F{entity_name}+"1st"]]></seriesExpression> <categoryExpression><![CDATA[$F{period_value}]]></categoryExpression> <valueExpression><![CDATA[new Double($F{result_value}.doubleValue()+5d)]]></valueExpression> <itemHyperlink > </itemHyperlink> </categorySeries> </categoryDataset> <linePlot > <plot /> <categoryAxisFormat> <axisFormat > </axisFormat> </categoryAxisFormat> <valueAxisFormat> <axisFormat > </axisFormat> </valueAxisFormat> </linePlot> </lineChart> </axis> <axis position="rightOrBottom" > <lineChart> <chart hyperlinkTarget="Self" > <reportElement x="-160" y="-1524" width="0" height="0" key="element-112"/> <box></box> <chartLegend textColor="#000000" backgroundColor="#FFFFFF" > </chartLegend> </chart> <categoryDataset> <dataset > <datasetRun subDataset="SubDataset2"> <datasetParameter name="filterParam2"> <datasetParameterExpression><![CDATA[$P{filterParam2}]]></datasetParameterExpression> </datasetParameter> <dataSourceExpression><![CDATA[$P{subDataSet2DS}]]></dataSourceExpression> </datasetRun> </dataset> <categorySeries> <seriesExpression><![CDATA[$F{entity_name}]]></seriesExpression> <categoryExpression><![CDATA[$F{period_value}]]></categoryExpression> <valueExpression><![CDATA[$F{result_value}]]></valueExpression> <itemHyperlink > </itemHyperlink> </categorySeries> </categoryDataset> <linePlot > <plot /> <categoryAxisFormat> <axisFormat > </axisFormat> </categoryAxisFormat> <valueAxisFormat> <axisFormat > </axisFormat> </valueAxisFormat> </linePlot> </lineChart> </axis> </multiAxisPlot> </multiAxisChart> </band> </summary></jasperReport>
×
×
  • Create New...