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

banania

Members
  • Posts

    6
  • Joined

  • Last visited

banania'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. Hello, Looks like you have multiple implementations (JARS) for XML parsing (multiples versions of xerces in classpath ?). gnujaxp(which comes with jfreechart) is also known to give this error. Try cleaning your JARS, or try the following tip : http://lostinheapspace.blogspot.com/2008/12/specify-documentbuilderfactory-with.html Hope this helps Banania
  2. Thanks for your answer. Yes good point, but checked the database and it's really a NULL value. If I check "blank on null" value is blanked. I made a really simple report just to reproduce problem. See below. Variable "variable1" just check if MT_LIB field is null. It prints 'false' is field is not null... but it print "null" instead of "true" if field is null. I'm losing my last hairs... <?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="report1" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20"> <property name="ireport.zoom" value="1.0"/> <property name="ireport.x" value="0"/> <property name="ireport.y" value="0"/> <queryString> <![CDATA[sELECT CO_NUMCO, LI_MTLIB FROM table1 WHERE field1 = 69906]]> </queryString> <field name="CO_NUMCO" class="java.lang.Integer"/> <field name="LI_MTLIB" class="java.lang.Double"/> <variable name="variable1" class="java.lang.String"> <variableExpression><![CDATA[$F{LI_MTLIB}==null]]></variableExpression> </variable> <background> <band splitType="Stretch"/> </background> <title> <band height="79" splitType="Stretch"/> </title> <pageHeader> <band height="35" splitType="Stretch"/> </pageHeader> <columnHeader> <band height="24" splitType="Stretch"> <staticText> <reportElement x="36" y="2" width="100" height="20"/> <textElement/> <text><![CDATA[CO_NUMCO]]></text> </staticText> <staticText> <reportElement x="189" y="2" width="100" height="20"/> <textElement/> <text><![CDATA[LI_MTLIB]]></text> </staticText> </band> </columnHeader> <detail> <band height="23" splitType="Stretch"> <textField> <reportElement x="19" y="0" width="100" height="20"/> <textElement/> <textFieldExpression class="java.lang.Integer"><![CDATA[$F{CO_NUMCO}]]></textFieldExpression> </textField> <textField> <reportElement x="150" y="0" width="100" height="20"/> <textElement/> <textFieldExpression class="java.lang.Double"><![CDATA[$F{LI_MTLIB}]]></textFieldExpression> </textField> <textField> <reportElement x="289" y="0" width="100" height="20"/> <textElement/> <textFieldExpression class="java.lang.String"><![CDATA[$V{variable1}]]></textFieldExpression> </textField> </band> </detail> <columnFooter> <band height="45" splitType="Stretch"/> </columnFooter> <pageFooter> <band height="54" splitType="Stretch"/> </pageFooter> <summary> <band height="42" splitType="Stretch"/> </summary> </jasperReport>
  3. Hello, Nobody has a clue ? Can it be some kink of bug ? Do I make something definitivly wrong ? Regards Banania
  4. Hola / Hello ;-) Can you post a screenshot ? May be it can help us understanding what's happening ? Regards Banania
  5. Hello, Seems like you are trying to add source files for iReports. Try to download jasper-reports full package and use the src folder in there. JRLoader is present ;-) http://sourceforge.net/projects/jasperreports/files/archive/jasperreports/ Regards Banania
  6. Hello guys, Well, almost all is said in the title. I currently have a strange behavior working with iReport ( / jasper reports) 4.0.2. : for some fiels and variables, i try to replace null values with fixed values (most of the time "0"). To do this simple thing, i use a small piece of code in the variable expression : ($F{MyField} == null) ? new Double("0") : $F{MyField} But i still get null values in the report. Before getting completely nuts, i made a new test with a new boolean variable : $F{MyField} == null and, surprise, it returns null. Ok now I understand why this is not working for my variables... but why is this condition not giving true when myField is null ? By the way, "Replace null by blank" option is working, but is not sufficient for my report. Does anyone have an idea ? Regards Banania
×
×
  • Create New...