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

markos17

Members
  • Posts

    25
  • 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 markos17

  1. ok, it works now. I use such formula: ($V{wylMeasure}.toPlainString() == "0") ? null: $V{wylMeasure} Thanks a lot!!!
  2. hehe, i know that distinguishing is a matter, but any clues, how to help my fantasy :)
  3. It almost works! There is just one issue. It also cut off cells with actual value of zero: "0.0000".
  4. thanks for the hint. It doesn't show error any more, but also still doesn't bring any effect. Now the formula is: ($V{wylMeasure} == new BigDecimal(0)) ? null : $V{wylMeasure} but still shows "0" It looks like, the formula can't find the "0". When I swaped formula into: ($V{wylMeasure} == new BigDecimal(0)) ? $V{wylMeasure} : null then all cell are empty. I also tried many other combination, like new BigDecimal("0") and so on.. When I change BigDecimal into String, then it works fine, show empty cells instead of "0", but the in the TOTAL column there are values from the previous column. I attach Excel File with an example. Any ideas, as I'm startin to give up :/ Post Edited by markos17 at 05/13/2010 11:12
  5. unfortunately, I have errors with types. how can i cast 0 from Int to BigDecimal? java:154: incomparable types: java.math.BigDecimal and int value = (java.math.BigDecimal)((((java.math.BigDecimal)variable_wylMeasure.getValue()) == 0) ? null
  6. I use Crosstable in which i show some values in different periods. I used to use Java.lang.string and eveyrthing was ok. When in database position didn't have any value, then in report it was the same. Last time, I wanted to use summary column, that'd sum all values in rows and columns. I had to change type to java.math.Bigdecimal. Since then instead of " ", it shows 0. Is there any way to solve it out?
  7. Yes, I'm using Row Group. It's essential in my case. I found some option->JasperReport Properties->PROPERTY_COLLAPSE_ROW_SPAN, it's set on false by deafault, but still cells are merged :/ Post Edited by markos17 at 04/22/2010 14:09
  8. I use crosstables in iReport. I have some problems. 1) Now, crosstabs merge my cells, I've attached screenshot with an example. Look at column B, I'd like to have spare names in every cell, like in colum N. 2) How to use default value for cells with no value? Now, when there is no data, crosstable shows "0" (eg. L49,L50,L51,L52). In database I set "0" for "d" and then crosstable shows "0.0000" (L53) Is it possible, to set some value, like "-" in case there is no data? 3) Last thing, which bothers me, is blocking cells/rows in Excel. I'd like to block the top row, so it's always visible, when I scroll XLS document down. Is this possible at all? Thanks in advance, for any help!
  9. I'm creating some reports in excel format. I'd like to block the top row, so it's always visible, when I scroll document down. Is such option available in Ireports 3.7.0?
  10. Thanks, it works in ireport, but in my application it generates such error: "javax.servlet.ServletException: java.lang.Exception: an error occur during report generation: org.xml.sax.SAXParseException: cvc-complex-type.3.2.2: Attribute 'ignoreWidth' is not allowed to appear in element 'crosstab'" Do you think, that I have to do some soft updates?
  11. Hi, Recently, I was generating some reports and have notice some issue. When I use collection parametr, it generates a couple of columns. When there are plenty of them, some of them are moved under the first ones. Is it possible to display all columns in one level in Excel? Now, it looks like this: 2009-08-01 2009-08-02 2009-08-03 2009-08-04 2009-08-05 2009-08-06 A 0 0 0 0 0 0 B 0 0 0 0 0 0 2009-08-07 2009-08-08 SUM A 0 0 0 B 0 0 0 I'd like to change it into this: 2009-08-01 2009-08-02 2009-08-03 2009-08-04 2009-08-05 2009-08-06 2009-08-07 2009-08-08 SUM A 0 0 0 0 0 0 0 0 0 B 0 0 0 0 0 0 0 0 0
  12. I am giving up :) all the time I get message: "Cannot cast from String to Boolean". The thing is, that Boolean class is set in my_field: ($F{my_field}==Boolean.TRUE?"Yes":"No") I also tried to use variable, all the time the same error. EDIT: Problem solved. I had to change class of the field in report into String. Post Edited by markos17 at 08/13/2009 12:02
  13. Thanks for reply. Anyway, I still have problems with that. I've tried to use Your syntax in report, eg. $F{(Field_1 == Boolean.TRUE ? "Yes":"No")} or in SQL: SELECT xyz FROM XYZ .abc WHERE Field_1 == Boolean.TRUE ? "Yes":"No" and still get errors messages. Where should I set this syntax? Post Edited by markos17 at 08/12/2009 13:37
  14. How can I replace boolean values, so in report it would be Yes/No instead of True/False?
  15. ok, I found the solution. All the time I was trying to set it up in Ireport. Finally, it was enough just to change one word in SQL. Instead of INNER JOIN, I used LEFT JOIN and now it works. There is just one small issue (additional column with zeros) When I choose AUTO it's all right then: Q1 Q2 Q3 TOTAL SOURCE A1 10 20 30 60 AUTO C4 5 10 15 10 AUTO When I choose ALL (AUTO and MANUAL) then it looks like this: Q1 Q2 Q3 TOTAL SOURCE A1 10 20 30 0 60 AUTO B2 0 6 MANUAL C4 5 10 15 0 10 AUTO D2 0 15 MANUAL E3 10 10 10 0 10 AUTO F4 10 10 10 0 30 AUTO In case of MANUAL: Q1 Q2 Q3 TOTAL SOURCE A1 0 33 MANUAL B3 0 25 MANUAL Do You have idea, how to remove that column with zeros?
  16. I can't generatre table, like You posted. When I try, I get such one: A1 AUTO Q1 10 A1 AUTO Q2 20 A1 AUTO Q3 30 C4 AUTO Q1 5 C4 AUTO Q2 10 C4 AUTO Q3 15 And beside I need column SUM (which is not always sum, I just got know, that sometimes it's sum and sometimes it's average!) Soo, finally the table should be like this (except brackets) Q1 Q2 Q3 TOTAL SOURCE A1 10 20 30 60 AUTO (TOTAL=SUM) B2 6 MANUAL C4 5 10 15 10 AUTO (TOTAL=AVG) D2 15 MANUAL E3 10 10 10 10 AUTO (TOTAL=AVG) F4 10 10 10 30 AUTO (TOTAL=SUM) I was trynig in such way: First, create crosstable only with AUTO source (I can do that now) Q1 Q2 Q3 TOTAL SOURCE A1 10 20 30 60 AUTO C4 5 10 15 10 AUTO Then create subreport with crosstable only with source MANUAL: TOTAL SOURCE B2 60 MANUAL D3 6 MANUAL E5 30 MANUAL and put it next to the previous one. Anyway, I have two problems. First is the positioning. I would like to put "AUTO" crosstab above the "MANUAL". When I try to use "column break", the system haning on and after few minutes give error message: "java.lang.OutOfMemoryError: Java heap space null". The second, much worse problem is how to transfer parameters to subreport from first report? In the first report, I use few parameters, which I use as a promts. The subreport doesn't have any parameters, so it uses all data. When I set (copy) parameters the same like in fist one, I get blank page.
  17. I've read my post and noticed, that it's really unclear ;) and besides I didn't give all facts, so I'll start again from beginning. It's the crosstab that I'd like to have: Q1 Q2 Q3 SUM SOURCE A1 10 20 30 60 AUTO B2 1 2 3 6 MANUAL C4 5 10 15 30 AUTO I created such crosstable, except the fact that there are no rows with SOURCE - MANUAL. There is an SQL table that contains data about period (Q1,Q2,Q3), which are related to partial values (same table). Only AUTO source have data in the table, that I mentioned before, so finally the crosstable misses MANUAL values. Before the table look like this: SUM SOURCE A1 60 AUTO B2 6 MANUAL C4 30 AUTO and there was no problem. Partial table was added recently and I'm thinking how to make it works out. Maybe some SubReport?
  18. I want to create report in Ireport using three tables. I will use such fields from every table: SOURCE and NAME from 1, SUM from 2 and PARTIAL_SUM from 3. There are two sources: Manual and Auto. The problem is, that fields with Auto have values in table 2-SUM and also PARTIAL_SUM in table 3. Fields with source Manual don't have values in table 3 (PARTIAL_SUM), but only in table 2 (SUM), so they are not in the report. Any ideas?
  19. I created such crosstable: xyz abc a1 10 a2 20 a3 30 Avg: 20 def a1 15 a2 10 a3 20 Avg: 15 TOTAL: 17,5 The thing is, that in TOTAL cell it counts average and I would like to count it as a sum of everything (37,5 instead of 17,5). Is it possible? Second thing that bothers me is divde by zero error. In two columns there are number values (BigDecimal). I want to create a new column with division: a1/b1. I did it and it works, but when b1=0, then I got divide by zero error. I tried to solve it using this: ({b1}!=0 ? (a1/b1 : 0) but then I got message that, parametr is missing. :/
  20. Thanks for such quick reply! Could You explain me the syntax: $X{IN, id_cicle, MY_COLLECTION_PARAMETER} ? In the first version: xyz 123 Jan yzx 321 Jan xzy 231 Jan I had such code: SELECT cycle.cycle, name, value FROM myData WHERE cycle.cyle = $P{id_cycle} Parameter "id_cycle " had class: "Java.lang.String". Should I change "id_cycle" Parametr class from "Java.lang.String" to "Java.util.Collection"? What about MY_COLLECTION_PARAMETER? Should I create such parameter? What value does it suppose to have? I tried with such syntax, but with poor results: SELECT cycle.cycle, name, value FROM myData WHERE cycle.cyle = $X{IN, id_cycle, MY_COLLECTION_PARAMETER} and BTW. Are You the author of this book: The Definitive Guide to iReport (Expert's Voice)? :) Post Edited by markos17 at 07/20/2009 13:32 Post Edited by markos17 at 07/20/2009 13:33
  21. I have created document with one parameter id_cycle (cycles names are January, February etc.) I can choose one from 12 cycles and report looks like this: name value cycle xyz 123 Jan yzx 321 Jan xzy 231 Jan Now, I would like to change it, so I can choose more than one cycle, eg. January, March and July. CYCLE: Jan name value xyz 123 yzx 321 SUM: 444 CYCLE: March name value zzz 111 yyy 222 SUM: 333 CYCLE: July name value xxx 001 zyz 100 SUM: 101 I tried with grouping and cross table. I don't know how to do it, that I can choose more than one cycle (parameter)? What do You think?
×
×
  • Create New...