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

thangalin

Members
  • Posts

    322
  • 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 thangalin

  1. What happens when you run the report's query directly against the database? Do you get rows back?
  2. I can't speak for them, but as a software developer, I'd prefer to see one bug that lists all the hardcoded English strings you find.
  3. Hi, It looks like what you are really after is something like: JFrame embedJasper = new JFrame(); embedJasper.add( new iReportFrame() ); iReports, as far as I can tell, uses the NetBeans framework. Here is an article I found: http://developers.sun.com/jsenterprise/archive/reference/techart/jse8/jasper_reports.html It should be possible to leverage NetBeans (possibly by developing your own plug-in?) to include both your application and the iReport application. The exact technical details on how you would do this will require much research. I'd recommend asking Giulio in an e-mail. He's really good at responding. See also: http://jasperforge.org/uploads/publish/ireportwebsite/IR%20Website/iReport_netbeans.html Post Edited by thangalin at 03/17/2010 16:27
  4. Here's how I integrate iReport. 1. Project manager and BA gather reporting requirements. 2. Write a database view that acquires the data for a report. 3. Write the report (in iReport) to display, format, and filter the data. 4. Integrate the .jasper file with the application framework (in this case, ADF). The end-users click a web page button to generate and download a PDF. The key API call: protected JasperPrint fillReport( InputStream report, Map parameters, Connection connection ) { return JasperFillManager.fillReport( report, parameters, connection ); } I wish I could publish the entire class and integration code, but it is not mine. Hope it helps!
  5. Hi, Use two static text fields, like this: INTERNAL LOGS - PrintWhenExpression: new Boolean( "KJSB".equalsIgnoreCase( $F{AGENCY} ) || "JANM".equalsIgnoreCase( $F{AGENCY} ) ).booleanValue() EXTERNAL LOGS - PrintWhenExpression: new Boolean( !"KJSB".equalsIgnoreCase( $F{AGENCY} ) && !"JANM".equalsIgnoreCase( $F{AGENCY} ) ).booleanValue() Post Edited by thangalin at 03/16/2010 21:01
  6. Sometimes when the report works inside iReport but does not work elsewhere it can be because of database rights. To solve this, I try to run the report's SQL statement against the database using the same database account used by the application. What usually happens is I discover that the application's database account does not have rights to run the SQL statement. (Missing GRANTs ...)
  7. http://www.jaspersoft.com/jasperserver Regular end-users probably shouldn't be using iReport to create reports. It is a rather complex piece of software. If, however, you put together a tutorial video for your users and created the SQL statements ahead of time, it might not be too bad. Still, I would never trust end-users to understand (much less use) SQL.
  8. You are most welcome. iReport is pretty amazing. When you get into subreports then you get to see its power unleashed. Good luck!
  9. One solution would be to use multiple texts with different PrintWhenExpression statements. For example: On Time - PrintWhenExpression: new Boolean( $F{so_difference}.intValue() <= 0 ).booleanValue() Late - PrintWhenExpression: new Boolean( $F{so_difference}.intValue() >= 1 ).booleanValue() No Data - PrintWhenExpression: new Boolean( $F{so_difference} == null ).booleanValue() (I do not recall if .booleanValue() is required; you might have to remove it -- including the period.) The reason might be because when $F{so_difference} is null, trying to call .intValue() will cause an error. That being the case, you might have to check for null values beforehand: On Time - PrintWhenExpression: $F{so_difference} == null ? Boolean.FALSE : new Boolean( $F{so_difference}.intValue() <= 0 ).booleanValue() Late - PrintWhenExpression: $F{so_difference} == null ? Boolean.FALSE : new Boolean( $F{so_difference}.intValue() >= 1 ).booleanValue() Personally, I dislike "hiding" static text values within code. I find reports easier to change when all static text values stand alone. The overlap might be confusing, but a future version of iReport might have layers to help resolve the overlap problem. Post Edited by thangalin at 03/16/2010 18:25
  10. Hi, How would you create a line in JasperReports that follows the trend for the data, in addition to showing the data points? From this: http://i.imgur.com/hOW8g.png To this: http://i.imgur.com/grMcm.png Is it possible? Post Edited by thangalin at 03/16/2010 18:29
  11. Have you tried using NVL? http://www.techonthenet.com/oracle/functions/nvl.php
  12. Hi, We want to present the user with a way to perform trends analysis. For this they would need to provide: Starting date (e.g., Jan 1st, 2009) Ending date (e.g., March 30th, 2009) Type of time for trend analysis (by year, month, day, or hour)The problem is in summation. I have a database view along the following lines: SELECT i.incident_id, d.occurrence_ts AS incident_date, to_number(to_char(d.occurrence_ts, 'YYYY' )) AS incident_year, to_number(to_char(d.occurrence_ts, 'MM' )) AS incident_month, to_number(to_char(d.occurrence_ts, 'DD' )) AS incident_day, to_number(to_char(d.occurrence_ts, 'HH' )) AS incident_hour, to_number(to_char(d.occurrence_ts, 'WW' )) AS incident_week FROM osc_incident i, osc_incident_detail d WHERE i.incident_id = d.incident_id; The database view returns all the incidents, and splits out the particular time units. In iReport, the report query is currently: SELECT count(incident_id) as tally, incident_day, trunc(incident_date, 'DD') AS incident_date FROM incident_report_vw GROUP BY incident_day, trunc(incident_date, 'DD') ORDER BY incident_date However, this would only allow the user to pick a start and end date, but no way to group the items. The Time series Data tab is filled out as follows: Series expression: "Incidents" Time period expression: $F{INCIDENT_DATE} Value expression: $F{TALLY} No lable expression valueOne of the issues is: How do you parameterize the Time period value on the Details tab? Any other ideas are most welcome.
  13. When you generate the report, use: JasperFillManager.fillReport( report, parameters, connection ); Where parameters is a Map instance. You can create a small Java program that acts as a bridge between your application and the shell.
  14. You can also use PrintWhenExpression. Usually converting the data to another format outside of JasperReports is a mistake. Keep your data pure; let the viewing layer (JasperReports) handle how to properly display the data.
  15. Reads like ad-hoc reporting. JasperSoft has an ad-hoc reporting tool.
  16. thangalin

    Ad Hoc Viewer Query

    Try new java.lang.Integer(0) vs new Integer(0). One of those won't work, I forget which.
  17. thangalin

    Ad Hoc Viewer Query

    Does not work in 3.7.0.
  18. Hi. I have updated the libraries to the following: jfreechart-01_00_12.jar jcommon-01_00_16.jar jasperreports-fonts-03_07_00.jar jasperreports-chart-themes-03_06_02.jar jasperreports-03_07_00.jar iText-02_01_06.jar castor-01_02_00.jar Same error: Caused by: java.lang.NoSuchMethodError: net.sf.jasperreports.charts.JRLinePlot.getCategoryAxisVerticalTickLabels()Ljava/lang/Boolean; at net.sf.jasperreports.chartthemes.simple.SimpleChartTheme.createXyLineChart(SimpleChartTheme.java:1494) I think it happens because the instance of JRLinePlot created using the factory does not implement getCategoryAxisVerticalTickLabels. Further, I have removed all instances of jfreechart-01_00_13.jar from the system. Strange. If I figure it out, I'll post a reply. More ideas are appreciated.
  19. I'd completely switch to the 3.7.0 version, then: 1. Remove the rectangle that is off. 2. Create it anew. 3. Align it using the "Align to Left Margin" button in the alignment window. I have run into similar problems when mixing 0.5 pixel widths with 1 pixel widths. I usually make everything 0.5 pixels and then alignment problems vanish. Good luck!
  20. What are you trying to do? What were you expecting? How is it wrong? What settings are you using for your fonts? What does your report look like?
  21. Depends on how you have it configured. The attached screen shot shows the step in the Wizard that allows you to select which database source is used by a subreport.
  22. Try: System.out.println( reportName+".jrxml" ); See if that file exists in the location that is printed.
×
×
  • Create New...