Jump to content
We've recently updated our Privacy Statement, available here ×

sinsand

Members
  • Posts

    47
  • Joined

  • Last visited

 Content Type 

Profiles

Forum

Events

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Security Advisories

Downloads

Everything posted by sinsand

  1. HI All, I need to show the multiselect parameters as names but while passing them to query, i need to pass the selected names as Id. Can anyone please suggest how this can be achived. Thanks, Sandeep
  2. Hi All, I have a scenrio in which the repeated values not to be printed in PDF but in Xls. isPrintrepatedValues flag is set in the jrxml itself, so Is there any property of JRXlsExporterParameter which I can use to set it so that while exportting in PDF it dosent show me the duplicate result but while exporting the report in Xls it shows me all the rows? Thanks, Sandeep
  3. HI All, can anyone help me regarding the following structure text---------totalCount----------TotalValue---------Count----------Value a 5 100 1 10 2 30 1 40 1 20 Currently we are getting the totalCount and TotalValue from the Second query where as we have the data for count and value in the first query and we are joining both the query. Will it be possible to add the count and value by the time of report generation and show it in the first row? Thanks. Sandeep
  4. Hi All, I am getting this error while trying to stop the Apache server, May 06, 2014 2:52:26 PM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/AdminServer] created a ThreadLocal with key of type [net.sf.jasperreports.engine.util.JRFontUtil$1] (value [net.sf.jasperreports.engine.util.JRFontUtil$1@782eb1b9]) and a value of type [java.util.HashSet] (value [[]]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak. I have search few links regarding the same error http://community.jaspersoft.com/questions/534340/memory-leak-jr-373 http://community.jaspersoft.com/questions/539890/memory-leaks-jasper-report-401 Can anyone from the community verify that this issue is fixed or not ? Or what can be done to resolve this so that I can stop my server.
  5. HI All, I am trying to pass object in parameter and trying to access its value but i am getting casting exception, the language is groovy Steps that i followed 1. passed the object in parameter params.latestOrderInstance = latestOrderInstance here latestOrderInstance is the variable name and the object is orderview. 2. In the jrxml i have put the parameter name as latestOrderInstance and its class as orderview. <parameter name="latestOrderInstance" class="xx.xx.xx.xx.OrdersView" isForPrompting="false"/> i have also imported the class <import value="xx.xx.xx.xx.OrdersView"/> 3. when i am trying to use the getter of that class it is giving me casting exception,I have tried syntax a. ((xx.xx.xx.xx.OrdersView)$P{latestOrderInstance}).getId() I am trying to display this in the textField, i have also put its expressionclass as orderview The exception i am getting is Cannot cast object 'xx.xx.xx.xx.OrdersView : 354' with class 'java.lang.String' to class 'xx.xx.xx.xx.OrdersView'. i have used scriptlet in some other report and they are using the same syntax and they are working fine Can anyone suggest what is wrong or how can i call getters of an object. Thanks, Sandeep
  6. HI Ankur, done what u have mentioned, and it worked without any error. Thanks
  7. Hi, what is the syntax of passing multiple scriptlet to the jrxml, i need multiple scriptlets as one scriptlet is for TOC, and i need to add one more for some calculation of the row. I tried passing like param("test_SCRIPTLET", test.Test), here test.Test is my java class. in jrxml i m reciving it as a parameter with class object as i tried many things and it was giving me casting exception. Can anyone tell me the syntax of passing the scriptlet other than scriptletClass, and how recive the scriptlet in jrxml. Thanks.
  8. hi below is the error, i am getting wne i am trying to pass a datasource to jasper from groovy Cannot cast object 'net.sf.jasperreports.engine.data.JRMapCollectionDataSource@9fa028' with class 'java.lang.String' to class 'net.sf.jasperreports.engine.data.JRMapCollectionDataSource'. My groovy code is List ls = new ArrayList(); Map mp = new HashMap(); mp.put("aa","a"); mp.put("bb","xx"); mp.put("cc",20.0); mp.put("dd",2.0); mp.put("ee",1.5); ls.add(mp); params.putAt("subReportData",new JRMapCollectionDataSource(ls)) My Main report.jrxml I am having it as a parameter <parameter name="subReportData" class="net.sf.jasperreports.engine.data.JRMapCollectionDataSource"> and passing this as a dataSourceExpression to the subreport Can any one suggests whats wrong? i have done this with java and that was working fine.
  9. HI , Is nested table is supported by jasper report? Like table inside table.
  10. didnt get that thing to work but someone from my team implemented the table so i have taken the code and changed it accordingly
  11. Hi, Is there a way by which i can put table inside a table or a subreport inside a table. I have tried subreport inside a table, the subreport itself is a table, it is getting compiled but when i try to run it, it gives me error that Subreport overflowed on a band that does not support overflow.. Stacktrace follows: Message: Subreport overflowed on a band that does not support overflow. I have checked printdetails when overflows in all report. Can anyone suggests what is wrong? The requirement: the header should not print on one page and data on other. I have tried subreport as well but sometimes the header is in one page and the data is in the other. Any solutions?
  12. Hi, I am getting the field not found error while compiling the report, the Data is coming from the datasource(It is a list and that list contains Map of string) List<Map<String,String>> ls = new ArrayList<Map<String,String>>(); Map<String,String> mp = new HashMap<String,String>(); mp.put("a", "1"); mp.put("b", "1"); mp.put("c", "1"); mp.put("d", "1"); ls.add(mp); mp = new HashMap<String,String>(); mp.put("a", "2"); mp.put("b", "2"); mp.put("c", "2"); mp.put("d", "2"); ls.add(mp); mp = new HashMap<String,String>(); mp.put("a", "3"); mp.put("b", "3"); mp.put("c", "3"); mp.put("d", "3"); ls.add(mp); mp = new HashMap<String,String>(); mp.put("a", "4"); mp.put("b", "4"); mp.put("c", "4"); mp.put("d", "4"); ls.add(mp); JRMapCollectionDataSource jr = new JRMapCollectionDataSource(ls); I am passing this as a parameter to the report. Below is the 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="reportTestForTable" language="groovy" pageWidth="555" pageHeight="802" columnWidth="555" leftMargin="0" rightMargin="0" topMargin="0" bottomMargin="0" uuid="f9782316-6526-4df8-bab0-6b0a47a3a0b1"> <property name="ireport.zoom" value="1.0"/> <property name="ireport.x" value="0"/> <property name="ireport.y" value="0"/> <style name="table"> <box> <pen lineWidth="1.0" lineColor="#000000"/> </box> </style> <style name="table_TH" mode="Opaque" backcolor="#F0F8FF"> <box> <pen lineWidth="0.5" lineColor="#000000"/> </box> </style> <style name="table_CH" mode="Opaque" backcolor="#BFE1FF"> <box> <pen lineWidth="0.5" lineColor="#000000"/> </box> </style> <style name="table_TD" mode="Opaque" backcolor="#FFFFFF"> <box> <pen lineWidth="0.5" lineColor="#000000"/> </box> </style> <subDataset name="New Dataset 1" uuid="9dfc72b9-ba88-4fa1-9e84-345dc60901c7"/> <parameter name="from_Date" class="java.lang.String"/> <parameter name="to_Date" class="java.lang.String"/> <parameter name="firm_Name" class="java.lang.String"/> <parameter name="symbol" class="java.lang.String"/> <parameter name="dataSourceForTable" class="net.sf.jasperreports.engine.data.JRMapCollectionDataSource"/> <field name="a" class="java.lang.String"> <fieldDescription><![CDATA[a]]></fieldDescription> </field> <field name="b" class="java.lang.String"> <fieldDescription><![CDATA]></fieldDescription> </field> <field name="c" class="java.lang.String"> <fieldDescription><![CDATA[c]]></fieldDescription> </field> <field name="d" class="java.lang.String"> <fieldDescription><![CDATA[d]]></fieldDescription> </field> <detail> <band height="125" splitType="Stretch"> <componentElement> <reportElement uuid="3b180264-95bb-4996-a4c4-184adb900d14" key="table" style="table" x="0" y="0" width="555" height="125"/> <jr:table xmlns:jr="http://jasperreports.sourceforge.net/jasperreports/components" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports/components http://jasperreports.sourceforge.net/xsd/components.xsd"> <datasetRun subDataset="New Dataset 1" uuid="e79040b7-74b9-4011-93f5-cab4a287554e"> <dataSourceExpression><![CDATA[$P{dataSourceForTable}]]></dataSourceExpression> </datasetRun> <jr:column width="90" uuid="a8c8758f-2da3-4a34-b699-057a072d5d16"> <jr:tableFooter style="table_TH" height="30" rowSpan="1"/> <jr:columnHeader style="table_CH" height="30" rowSpan="1"> <staticText> <reportElement uuid="a2498360-341e-44c7-a8d6-04f697e805de" x="0" y="0" width="90" height="30"/> <textElement/> <text><![CDATA[a]]></text> </staticText> </jr:columnHeader> <jr:columnFooter style="table_CH" height="30" rowSpan="1"/> <jr:detailCell style="table_TD" height="20" rowSpan="1"> <textField> <reportElement uuid="69f779ca-f7ae-456d-b5ad-1ad59b07e5ba" x="0" y="0" width="90" height="20"/> <textElement/> <textFieldExpression><![CDATA[$F{a}]]></textFieldExpression> </textField> </jr:detailCell> </jr:column> <jr:column width="90" uuid="1edf8e29-cfef-4d91-8544-16d8f7b47b5c"> <jr:tableFooter style="table_TH" height="30" rowSpan="1"/> <jr:columnHeader style="table_CH" height="30" rowSpan="1"> <staticText> <reportElement uuid="f4cc873f-e5fa-46e9-9eab-ff01ba568251" x="0" y="0" width="90" height="30"/> <textElement/> <text><![CDATA]></text> </staticText> </jr:columnHeader> <jr:columnFooter style="table_CH" height="30" rowSpan="1"/> <jr:detailCell style="table_TD" height="20" rowSpan="1"> <textField> <reportElement uuid="1f710708-ccc0-41d6-b2ce-b4d03408c346" x="0" y="0" width="90" height="20"/> <textElement/> <textFieldExpression><![CDATA[$F{b}]]></textFieldExpression> </textField> </jr:detailCell> </jr:column> <jr:column width="90" uuid="4e908dab-4da2-460c-884a-67d616415935"> <jr:tableFooter style="table_TH" height="30" rowSpan="1"/> <jr:columnHeader style="table_CH" height="30" rowSpan="1"> <staticText> <reportElement uuid="e329904d-69c4-4f1c-ba4b-ef6527488cd8" x="0" y="0" width="90" height="30"/> <textElement/> <text><![CDATA[c]]></text> </staticText> </jr:columnHeader> <jr:columnFooter style="table_CH" height="30" rowSpan="1"/> <jr:detailCell style="table_TD" height="20" rowSpan="1"> <textField> <reportElement uuid="6b23b830-94c9-4fc9-a9df-905211422166" x="0" y="0" width="90" height="20"/> <textElement/> <textFieldExpression><![CDATA[$F{c}]]></textFieldExpression> </textField> </jr:detailCell> </jr:column> <jr:column width="90" uuid="8e4ff569-fa21-420e-8580-120f737a2efa"> <jr:tableFooter style="table_TH" height="30" rowSpan="1"/> <jr:columnHeader style="table_CH" height="30" rowSpan="1"> <staticText> <reportElement uuid="c4213608-6c1b-4af9-8ab8-c017d5a15131" x="0" y="0" width="90" height="30"/> <textElement/> <text><![CDATA[d]]></text> </staticText> </jr:columnHeader> <jr:columnFooter style="table_CH" height="30" rowSpan="1"/> <jr:detailCell style="table_TD" height="20" rowSpan="1"> <textField> <reportElement uuid="4e27cd2e-1879-4a32-a78a-d79c589d71a3" x="0" y="0" width="90" height="20"/> <textElement/> <textFieldExpression><![CDATA[$F{d}]]></textFieldExpression> </textField> </jr:detailCell> </jr:column> </jr:table> </componentElement> </band> </detail> </jasperReport> Can anyone suggest what is wrong?
  13. Hi, can anyone explains what will be the performance impact or which will be better if we use 1. query in jrxml 2. query in java and send the data as datasource to the jrxml Assumptions 1. we have to display 50000 or more data. 2. no of times the Query fired are same 3. if we are using query in jrxml then the main report has subreports with in subreports and those subreports also contains queries. Thanks
  14. i know this is the issue with this apporach but can anyone tell when this issue will be resolved in Jasper Report or any other way to resolve it?
  15. Got it, as it is the issue with this approach, i read the static text few hours later after my all search was done
  16. HI, I have implemented the TOC as mentioned in the jasper example but the LocalAnchor link is pointing to the wrong page as the pages are cut after the JRPrint Object is created and pasted at the TOP of the Document, so the redirect to the page in the same document is not working properly. I have also tried LocalPage LocalPage LocalPage LocalPage as well but the same issue occurs. Can anyone suggest LocalAnchor should be implemented to go to the page when clicking in the TOC. or any other alternative or did i miss something?
  17. Sorry for posting an illogical Question as the last number of page cannot be calculated before the print object is created(My guess, it may be wrong).I hope no body has spent time on it.
  18. Thanks ilona for ur reply, I used the samples from the jasper report and it is working fine, but the page number starts from 1 of the content, i.e. the TOC does not have the Page number and if it did those will be of the last pages right? as we are cutting the last pages and pasting it in the top of the document. Is there a Way by which we can give the TOC page numbers with correct page numbers in the report as well?
  19. HI Is there a way in which we can compile or build the jasper print object from bottom to up so that the TOC will be known. Please suggest. Thanks
  20. HI, the samples i found on net is saying about the single page TOC, Can anyone suggests how can we implement multipage TOC, Requirement : To create a Toc for a report. but the report contains 1000 page data and from those pages we have to create a TOC so the TOC will come in multiple pages so how to resolve the issue of correct pages or how to implement this scenrio. Simply put i need to create a TOC which is more than one page. Can anyone suggest how this can be implemented?
  21. HI All, for the above question is that possible or not in jasper report, can anybody who is expert in jasper report tell me or help me out ???
  22. Hi All, Can we pass any data by parameter or field to reportElement tag Like <reportElement x="345" y="2" width="45" forecolor="$F{ProposedColor}"/> can anybody help me out ? I need to pass color to reportElement to make it more customized as per project requirement. or I need to display each field with different Color how can i achive that ??
×
×
  • Create New...