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

reportdev

Members
  • Posts

    413
  • Joined

  • Last visited

 Content Type 

Profiles

Forum

Events

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Downloads

Everything posted by reportdev

  1. Check this feed http://community.jaspersoft.com/blog/tip-japsersoft-design-studio-metadatalog-error
  2. are you passing any parameters into the tables ? check if you missed it on the second table
  3. In the outline, Expand the Fields section select all fields by holding shift key and then drag all the fields to detail band.
  4. How can i set differents styles by row type?one way would be to create a uniqueid in your sql and assign this uniqueid to the conditional expression How can i add the sub row with total if there are more than 1 subrow?I can think of creating groups for each row and creating variables from the group would create subtotals. How can i manage sub rows inside a row with jasper?Inside these Row groups, create table elements for Sub rows.
  5. I'm not sure about java.awt.Color, but found another easy way to perform the background coloring dynamically. I have used a HTML element and used a bgcolor html tag to evaluate the hex color at runtime. "<body bgcolor=" + $F{COLOR} + "><h1>Hello world!</h1><p></p></body>"
  6. The getting started page displays with the flowId=homeFlow Try localhost:8080/jasperserver/flow.html?_flowId=homeFlow The redirection settings are located in jasperserver-servlet-pro.xml.
  7. <?xml version="1.0" encoding="UTF-8"?><!-- Created with Jaspersoft Studio version 6.2.0.final using JasperReports Library version 6.2.0 --><!-- 2017-01-20T11:28:34 --><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="Blank_A4" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" whenResourceMissingType="Error" uuid="9f00c1c7-09ad-4cdb-a26c-48d2f2038207"> <property name="com.jaspersoft.studio.unit." value="pixel"/> <property name="com.jaspersoft.studio.unit.pageHeight" value="pixel"/> <property name="com.jaspersoft.studio.unit.pageWidth" value="pixel"/> <property name="com.jaspersoft.studio.unit.topMargin" value="pixel"/> <property name="com.jaspersoft.studio.unit.bottomMargin" value="pixel"/> <property name="com.jaspersoft.studio.unit.leftMargin" value="pixel"/> <property name="com.jaspersoft.studio.unit.rightMargin" value="pixel"/> <property name="com.jaspersoft.studio.unit.columnWidth" value="pixel"/> <property name="com.jaspersoft.studio.unit.columnSpacing" value="pixel"/> <property name="com.jaspersoft.studio.data.sql.tables" value=""/> <style name="Table_TH" mode="Opaque" backcolor="#F0F8FF"> <box> <pen lineWidth="0.5" lineColor="#000000"/> <topPen lineWidth="0.5" lineColor="#000000"/> <leftPen lineWidth="0.5" lineColor="#000000"/> <bottomPen lineWidth="0.5" lineColor="#000000"/> <rightPen lineWidth="0.5" lineColor="#000000"/> </box> </style> <style name="Table_CH" mode="Opaque" backcolor="#BFE1FF"> <box> <pen lineWidth="0.5" lineColor="#000000"/> <topPen lineWidth="0.5" lineColor="#000000"/> <leftPen lineWidth="0.5" lineColor="#000000"/> <bottomPen lineWidth="0.5" lineColor="#000000"/> <rightPen lineWidth="0.5" lineColor="#000000"/> </box> </style> <style name="Table_TD" mode="Opaque" backcolor="#FFFFFF"> <box> <pen lineWidth="0.5" lineColor="#000000"/> <topPen lineWidth="0.5" lineColor="#000000"/> <leftPen lineWidth="0.5" lineColor="#000000"/> <bottomPen lineWidth="0.5" lineColor="#000000"/> <rightPen lineWidth="0.5" lineColor="#000000"/> </box> </style> <style name="Table 1_TH" mode="Opaque" backcolor="#F0F8FF"> <box> <pen lineWidth="0.5" lineColor="#000000"/> <topPen lineWidth="0.5" lineColor="#000000"/> <leftPen lineWidth="0.5" lineColor="#000000"/> <bottomPen lineWidth="0.5" lineColor="#000000"/> <rightPen lineWidth="0.5" lineColor="#000000"/> </box> </style> <style name="Table 1_CH" mode="Opaque" backcolor="#BFE1FF"> <box> <pen lineWidth="0.5" lineColor="#000000"/> <topPen lineWidth="0.5" lineColor="#000000"/> <leftPen lineWidth="0.5" lineColor="#000000"/> <bottomPen lineWidth="0.5" lineColor="#000000"/> <rightPen lineWidth="0.5" lineColor="#000000"/> </box> </style> <style name="Table 1_TD" mode="Opaque" backcolor="#FFFFFF"> <box> <pen lineWidth="0.5" lineColor="#000000"/> <topPen lineWidth="0.5" lineColor="#000000"/> <leftPen lineWidth="0.5" lineColor="#000000"/> <bottomPen lineWidth="0.5" lineColor="#000000"/> <rightPen lineWidth="0.5" lineColor="#000000"/> </box> </style> <subDataset name="Dataset1" uuid="276df825-0b12-4d93-ad31-8d4eb16741cd"> <property name="com.jaspersoft.studio.data.sql.tables" value=""/> <property name="com.jaspersoft.studio.data.defaultdataadapter" value="Sample DB"/> <parameter name="ORDERID" class="java.lang.Integer"/> <parameter name="CUSTOMERID" class="java.lang.String"/> <parameter name="EMPLOYEEID" class="java.lang.Integer"/> <queryString> <![CDATA[select * from orderswhere(ORDERID = $P{ORDERID} )or(CUSTOMERID = $P{CUSTOMERID} )or(EMPLOYEEID = $P{EMPLOYEEID} )]]> </queryString> <field name="ORDERID" class="java.lang.Integer"/> <field name="CUSTOMERID" class="java.lang.String"/> <field name="EMPLOYEEID" class="java.lang.Integer"/> <sortField name="ORDERID"/> <sortField name="CUSTOMERID"/> <sortField name="EMPLOYEEID"/> </subDataset> <parameter name="ORDERID" class="java.lang.Integer"/> <parameter name="CUSTOMERID" class="java.lang.String"> <parameterDescription><![CDATA[]]></parameterDescription> </parameter> <parameter name="EMPLOYEEID" class="java.lang.Integer"/> <queryString> <![CDATA[select * from orders]]> </queryString> <field name="ORDERID" class="java.lang.Integer"/> <field name="CUSTOMERID" class="java.lang.String"/> <field name="EMPLOYEEID" class="java.lang.Integer"/> <field name="ORDERDATE" class="java.sql.Timestamp"/> <field name="REQUIREDDATE" class="java.sql.Timestamp"/> <field name="SHIPPEDDATE" class="java.sql.Timestamp"/> <field name="SHIPVIA" class="java.lang.Integer"/> <field name="FREIGHT" class="java.math.BigDecimal"/> <field name="SHIPNAME" class="java.lang.String"/> <field name="SHIPADDRESS" class="java.lang.String"/> <field name="SHIPCITY" class="java.lang.String"/> <field name="SHIPREGION" class="java.lang.String"/> <field name="SHIPPOSTALCODE" class="java.lang.String"/> <field name="SHIPCOUNTRY" class="java.lang.String"/> <background> <band splitType="Stretch"/> </background> <summary> <band height="40"> <componentElement> <reportElement x="0" y="0" width="555" height="40" uuid="6a587605-24fc-463c-b0d2-951d1cf79c69"> <property name="com.jaspersoft.studio.layout" value="com.jaspersoft.studio.editor.layout.VerticalRowLayout"/> </reportElement> <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="Dataset1" uuid="7285622c-58e8-45af-8a62-f63d55444319"> <datasetParameter name="CUSTOMERID"> <datasetParameterExpression><![CDATA[$P{CUSTOMERID}]]></datasetParameterExpression> </datasetParameter> <datasetParameter name="EMPLOYEEID"> <datasetParameterExpression><![CDATA[$P{EMPLOYEEID}]]></datasetParameterExpression> </datasetParameter> <datasetParameter name="ORDERID"> <datasetParameterExpression><![CDATA[$P{ORDERID}]]></datasetParameterExpression> </datasetParameter> <connectionExpression><![CDATA[$P{REPORT_CONNECTION}]]></connectionExpression> </datasetRun> <jr:column width="180" uuid="136cfb9c-9a82-433d-b657-c07594d897b7"> <property name="com.jaspersoft.studio.unit.width" value="pixel"/> <printWhenExpression><![CDATA[(!$P{ORDERID}.equals(null))== true]]></printWhenExpression> <jr:columnHeader style="Table 1_CH" height="20"> <property name="com.jaspersoft.studio.unit.width" value="px"/> <property name="com.jaspersoft.studio.unit.height" value="px"/> <staticText> <reportElement x="0" y="0" width="180" height="20" uuid="65809bae-ceee-459d-99b5-81031dbd6695"/> <box leftPadding="5"/> <textElement verticalAlignment="Middle"> <font isBold="true" isUnderline="true"/> </textElement> <text><![CDATA[ORDERID]]></text> </staticText> </jr:columnHeader> <jr:detailCell style="Table 1_TD" height="20"> <property name="com.jaspersoft.studio.unit.height" value="px"/> <textField> <reportElement x="0" y="0" width="180" height="20" uuid="79b6944c-0460-4da3-88ba-11ebdfbaed90"/> <box leftPadding="5"/> <textElement verticalAlignment="Middle"/> <textFieldExpression><![CDATA[$F{ORDERID}]]></textFieldExpression> </textField> </jr:detailCell> </jr:column> <jr:column width="200" uuid="48fccd5c-4ba2-477e-86d2-581754ca8df0"> <property name="com.jaspersoft.studio.unit.width" value="pixel"/> <printWhenExpression><![CDATA[(!$P{CUSTOMERID}.equals(null))== true]]></printWhenExpression> <jr:columnHeader style="Table 1_CH" height="20"> <property name="com.jaspersoft.studio.unit.width" value="px"/> <property name="com.jaspersoft.studio.unit.height" value="px"/> <staticText> <reportElement x="0" y="0" width="200" height="20" uuid="6ca7facf-140e-43e7-875d-c7138fcf488c"/> <box leftPadding="5"/> <textElement verticalAlignment="Middle"> <font isBold="true" isUnderline="true"/> </textElement> <text><![CDATA[CUSTOMERID]]></text> </staticText> </jr:columnHeader> <jr:detailCell style="Table 1_TD" height="20"> <property name="com.jaspersoft.studio.unit.height" value="px"/> <textField> <reportElement x="0" y="0" width="200" height="20" uuid="4df4059c-5430-44ba-beed-7c5878c6d426"/> <box leftPadding="5"/> <textElement verticalAlignment="Middle"/> <textFieldExpression><![CDATA[$F{CUSTOMERID}]]></textFieldExpression> </textField> </jr:detailCell> </jr:column> <jr:column width="170" uuid="07332bb7-ff68-430a-98ed-3a35025436cb"> <property name="com.jaspersoft.studio.unit.width" value="pixel"/> <printWhenExpression><![CDATA[(!$P{EMPLOYEEID}.equals(null))== true]]></printWhenExpression> <jr:columnHeader style="Table 1_CH" height="20"> <property name="com.jaspersoft.studio.unit.width" value="px"/> <property name="com.jaspersoft.studio.unit.height" value="px"/> <staticText> <reportElement x="0" y="0" width="170" height="20" uuid="72125348-ce1b-44e7-9977-dbcff95a978e"/> <box leftPadding="5"/> <textElement verticalAlignment="Middle"> <font isBold="true" isUnderline="true"/> </textElement> <text><![CDATA[EMPLOYEEID]]></text> </staticText> </jr:columnHeader> <jr:detailCell style="Table 1_TD" height="20"> <property name="com.jaspersoft.studio.unit.height" value="px"/> <textField> <reportElement x="0" y="0" width="170" height="20" uuid="c49e8e00-ba67-4df2-8808-e0290460d643"/> <box leftPadding="5"/> <textElement verticalAlignment="Middle"/> <textFieldExpression><![CDATA[$F{EMPLOYEEID}]]></textFieldExpression> </textField> </jr:detailCell> </jr:column> </jr:table> </componentElement> </band> </summary></jasperReport>[/code]I have written this jrxml for the same purpose. when you enter some value into the parameter for the respective column, it disappears. Check the print when expression on the Columns
  8. The labels can contain special characters, but the parameter name in the jrxml cannot contain special characters. While displaying your report in the server, change the input control label
  9. I think you are losing some precision while converting integers to bigdecimals and also while rounding.
  10. Parameters cannot contain any special characters Change it to StartDate or Start_Date
  11. I think special characters are not allowed in the parameter. https://www.tutorialspoint.com/jasper_reports/jasper_report_parameters.htm instead try using the Prompt Text (required) as 'Quarter(1,2,3,4)' and the parameter name as Quarter
  12. In the table element properties, -> Dataset -> Parameters -> add your parameter mapping from the main report to table element
  13. If you are talking about values from a sql not getting sorted, then in the Outline, you can use Sort Fields and sort the fields as per you need. If you are talking about list element, I have tried the same use case and it is sorting the values by default. check this jrxml <?xml version="1.0" encoding="UTF-8"?><!-- Created with Jaspersoft Studio version 6.2.0.final using JasperReports Library version 6.2.0 --><!-- 2017-01-17T08:33:44 --><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="Blank_A4_2" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="7980397a-5175-4537-bd09-edc66d92a625"> <property name="com.jaspersoft.studio.data.defaultdataadapter" value="PRODSUP"/> <property name="com.jaspersoft.studio.data.sql.tables" value=""/> <subDataset name="list" uuid="3de8d4a4-f519-4692-a8f6-ab3e8654f217"> <property name="com.jaspersoft.studio.data.sql.tables" value=""/> <queryString> <![CDATA[select 1 as ID from dualunionselect 4 as ID from dualunionselect 2 as ID from dualunionselect 3 as ID from dual]]> </queryString> <field name="ID" class="java.math.BigDecimal"/> <variable name="Count" class="java.lang.Integer" calculation="Count"> <variableExpression><![CDATA[$F{ID}]]></variableExpression> </variable> <variable name="max_count" class="java.lang.Integer" calculation="Highest"> <variableExpression><![CDATA[$V{Count}]]></variableExpression> </variable> </subDataset> <queryString> <![CDATA[select * from dual]]> </queryString> <field name="DUMMY" class="java.lang.String"/> <background> <band splitType="Stretch"/> </background> <detail> <band height="20" splitType="Stretch"> <componentElement> <reportElement x="0" y="0" width="200" height="20" uuid="9afe7f5a-eb09-48d0-b102-891ca089c427"> <property name="net.sf.jasperreports.export.headertoolbar.table.name" value=""/> </reportElement> <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="list" uuid="00b13a3b-b8f1-4257-ba2e-3fb20996e0de"> <connectionExpression><![CDATA[$P{REPORT_CONNECTION}]]></connectionExpression> </datasetRun> <jr:listContents height="20" width="200"> <textField> <reportElement x="0" y="0" width="100" height="20" uuid="1a0bbd56-549e-4ece-91e0-01e2c3bb4309"/> <textFieldExpression><![CDATA[$F{ID}]]></textFieldExpression> </textField> </jr:listContents> </jr:list> </componentElement> </band> </detail></jasperReport>[/code]
  14. In order for the subreport to get initiated, a report connection is needed from the main report. the main report should have some data to initiate the report connection and send it to the subreport. in the main report sql, use some dummy data
  15. net.sf.jasperreports.export.xls.freeze.column net.sf.jasperreports.export.xls.freeze.column.edge net.sf.jasperreports.export.xls.freeze.row net.sf.jasperreports.export.xls.freeze.row.edgeAbove properties can be used for this purpose.
  16. Click on the yellow highlighted tab and you should be able to go back to the main report.
  17. yes, use a conditional expression with the hyperlinks in the _report parameter
  18. i think one way of accessing jasper reports from Oracle forms would be making a REST Call to the server with web.showdocument(url,'_blank') from the Oracle forms.
  19. try using the new jaspersoft studio and see if it works.ireports is not supported. the hyperlinks will not work in the studio. the report needs to be published into the server for the hyperlinks to be active.
  20. Find the viewReportBeans.xml file at below location and comment out the unncessary export options C:Jaspersoftjasperreports-server-cp-6.2.0apache-tomcatwebappsjasperserverWEB-INFflowsviewReportBeans.xml <util:map id="exporterConfigMap"> <!-- comment/uncomment any of the lines below if you want related exporters to be excluded/included in the viewer's exporters list Note: separate configuration for iPad 'exportersSupportedByiPad' --> <entry key="pdf" value-ref="pdfExporterConfiguration"/> <entry key="csv" value-ref="csvExporterConfiguration"/> <entry key="rtf" value-ref="rtfExporterConfiguration"/> <entry key="xlsx" value-ref="xlsxExporterConfiguration"/> <entry key="xlsxNoPag" value-ref="xlsxNoPaginationExporterConfiguration"/> <!-- <entry key="xls" value-ref="xlsExporterConfiguration"/> <entry key="xlsNoPag" value-ref="xlsNoPaginationExporterConfiguration"/> <entry key="docx" value-ref="docxExporterConfiguration"/> <entry key="odt" value-ref="odtExporterConfiguration"/> <entry key="ods" value-ref="odsExporterConfiguration"/> <entry key="pptx" value-ref="pptxExporterConfiguration"/> <entry key="txt" value-ref="txtExporterConfiguration"/> --> </util:map>
  21. create the parameter as arraylist and use the below filter expression $P{Parameter}.contains($F{Field} ) == true
  22. after evaluating the sql in the dataset and query window, the fields will be added to the table element. after adding, double click on the table elementexpand the Table -> click on any of the bands and expand (Table Header / Column Header / Detail / Column Footer/Table Footer)you should see columns.right click on one of the columns and click Create Column after or Create Column Before
×
×
  • Create New...