Jump to content
Changes to the Jaspersoft community edition download ×

ernst_2

Members
  • Posts

    31
  • 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 ernst_2

  1. You can use the "Column Header" and a "Group Footer".
  2. It looks all completely fine, I think your browser displays the content not correct.
  3. try: ($F{lastcost} >= ($F{sellprice} /1.40) ? "Low Sell" : ($F{lastcost} >= ($F{sellprice} / 1.80) && ($F{lastcost} < 25) ? "Low Sell" : "OK"))
  4. try $F{FilmName}.equals("Jurassic Park") Edit: Sorry, I didn’t notice that you find the solution yourself And != works, because the object references are not the same
  5. Is the "compatibility mode" deactivated? Press F12 and change the "Browser Mode".
  6. You have to use the Java-Functions like: $P{JASPER_REPORTS_CONTEXT} != null ? $P{JASPER_REPORTS_CONTEXT}.getProperties() : ""
  7. Hi jonathan_20, maybe it helps to set the JDK-Home-Path in the iReport-Config "<path>iReport-5.6.0etcireport.conf"-File, like jdkhome="C:Program Files (x86)Javajdk1.7.0_75". And don't use a jdk above 1.7.
  8. Rename your my.txt to my.csv and insert content like: <columnName0>, <columnName1> <value01>, <value11> <value02>, <value12> <value03>, <value13> And use "CSV File" as data adapter. If you need the file on the server, follow this description (not tested): http://community.jaspersoft.com/questions/802580/how-create-excel-data-source-jasperreports-server
  9. I think it an SSL problem, with SSL i get "There is a problem with selected Datasource which is not valid", without SSL it's working. (version 6.1.0) And thats not the only problem with a SSL-Connection.
  10. You need to use the provided $X{} functions for such inputs. Like: $X{IN, <column_name>, <parameter_name>} Description: http://jasperreports.sourceforge.net/sample.reference/query/
  11. Hi j.t.casperson, you can find the description in this properties file: "...jasperreports-server-cp-5.6.0apache-tomcatwebappsjasperserverWEB-INFbundlesjasperserver_messages.properties" The attribute is called "DATE_IC_TOOLTIP".
  12. Found it! <parameter name="P_SUB_DATASOURCE" class="com.jaspersoft.jasperserver.api.metadata.jasperreports.domain.JdbcReportDataSource" isForPrompting="false"> <defaultValueExpression><![CDATA[com.jaspersoft.jasperserver.api.engine.jasperreports.util.RepositoryUtil.getThreadRepositoryContext().getRepository().getResource(null,"/<path to data source>/")]]></defaultValueExpression></parameter>[/code]<parameter name="P_SUB_CONNECTION" class="java.sql.Connection" isForPrompting="false"> <defaultValueExpression><![CDATA[java.sql.DriverManager.getConnection($P{P_SUB_DATASOURCE}.getConnectionUrl(),$P{P_SUB_DATASOURCE}.getUsername(),$P{P_SUB_DATASOURCE}.getPassword())]]></defaultValueExpression></parameter> [/code]<subreport> <reportElement mode="Opaque" x="555" y="0" width="5" height="20"/> <subreportParameter name="P_B"> <subreportParameterExpression><![CDATA[$F{user}]]></subreportParameterExpression> </subreportParameter> <connectionExpression><![CDATA[$P{P_SUB_CONNECTION}]]></connectionExpression> <returnValue subreportVariable="V_M" toVariable="V_M"/> <subreportExpression><![CDATA["repo:0001_Subreport.jrxml"]]></subreportExpression></subreport>[/code]<textField> <reportElement x="555" y="10" width="5" height="20"/> <textElement verticalAlignment="Middle"/> <textFieldExpression><![CDATA[""; $P{P_SUB_CONNECTION}.close()]]></textFieldExpression></textField>[/code]
  13. Hi, my subreport connects successfully to a different database, by the description of ntatlock. Like: <subreport> <reportElement mode="Opaque" x="555" y="0" width="5" height="20"/> <subreportParameter name="P_B"> <subreportParameterExpression><![CDATA[$F{username}]]></subreportParameterExpression> </subreportParameter> <connectionExpression><![CDATA[java.sql.DriverManager.getConnection($P{P_SUB_DATASOURCE}.getConnectionUrl(),$P{P_SUB_DATASOURCE}.getUsername(),$P{P_SUB_DATASOURCE}.getPassword())]]></connectionExpression> <returnValue subreportVariable="V_M" toVariable="V_M"/> <subreportExpression><![CDATA["repo:0001_Subreport.jrxml"]]></subreportExpression></subreport>[/code]But the connection is not closing. So what can I do, to close the connection?
  14. Maybe "equals" will help you. Like: $F{dataAsOfDate}.equals($V{maxDate})
  15. Hi infrocio, to run iReport your Java JDK-Version must be below 1.8. Or maybe it helps to set the JDK-Home-Path in the iReport-Config "<path>iReport-5.6.0etcireport.conf"-File, like jdkhome="C:Program Files (x86)Javajdk1.7.0_75".
  16. Hi, I have tried it, but I get this error (by iReport and the Server): "net.sf.jasperreports.engine.rd.DateRange cannot be resolved to a type" Is something missing? Solved: I use "net.sf.jasperreports.types.date.DateRange" now.
  17. Hi Ravi Kumar, I solved this problem with the LoggedInUsername parameter and some extra tables in the database, to manage the access over the sql-query.
  18. If it is the community edition there is no "Ad Hoc Report Designer", otherwise there should be a CREATE button in the menu.
  19. I use also a TextField like this: TextField: expression: $F{sem} pattern: #,##0.00 The pattern does not change the value itself, it’s only for printing. And I don't know how you manage it, to calculate with the rounded value of the TextField.
  20. It's magic :D No, it's very simple. You only have to pass your field into the expression of a variable and use the sum calculation type. SQL: SELECT 0.5344 AS SEMUNION ALLSELECT 508.564UNION ALLSELECT 508.495899999999UNION ALLSELECT 69.8347[/code]Variable: name: SUM_SEM class: java.math.BigDecimal calculation: Sum reset type: report increment type: none variable expression: $F{sem} TextField: expression: $V{SUM_SEM} pattern: #,##0.00
  21. Are you sure, that you use the sum function right? (you have to sum the unrounded values) Because this is my result of the report and I think this is what you want.
  22. Hi sara.machado, I am not sure why the pattern is not working for you. This is my test file and it seems to work correctly: <?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="report2" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" isFloatColumnFooter="true" uuid="7d1d2338-32cf-402d-bcde-e20af78120ae"> <property name="ireport.zoom" value="1.0"/> <property name="ireport.x" value="0"/> <property name="ireport.y" value="0"/> <queryString> <![CDATA[sELECT 0.5344 AS SEMUNION ALLSELECT 508.564UNION ALLSELECT 508.495899999999UNION ALLSELECT 69.8347]]> </queryString> <field name="sem" class="java.math.BigDecimal"/> <variable name="SUM_SEM" class="java.math.BigDecimal" calculation="Sum"> <variableExpression><![CDATA[$F{sem}]]></variableExpression> </variable> <columnHeader> <band height="20" splitType="Stretch"> <staticText> <reportElement x="0" y="0" width="100" height="20" uuid="470afba4-c01c-46ef-ac75-b960c8f55bd0"/> <text><![CDATA[sem]]></text> </staticText> </band> </columnHeader> <detail> <band height="20" splitType="Stretch"> <textField pattern="#,##0.00"> <reportElement x="0" y="0" width="100" height="20" uuid="eb7dd5f0-922f-4b4c-8c32-93bbb01571dc"/> <textFieldExpression><![CDATA[$F{sem}]]></textFieldExpression> </textField> </band> </detail> <columnFooter> <band height="20" splitType="Stretch"> <textField pattern="#,##0.00"> <reportElement x="0" y="0" width="100" height="20" uuid="f7409b2d-0a68-49e2-a786-f4cb1761c2e0"/> <textElement> <font isBold="true"/> </textElement> <textFieldExpression><![CDATA[$V{SUM_SEM}]]></textFieldExpression> </textField> </band> </columnFooter></jasperReport>[/code]
  23. Hi, Java 1.8 is not working, use a lower version like 1.7. See also: http://community.jaspersoft.com//questions/912076/i-cant-open-ireport560
×
×
  • Create New...