Jump to content
Changes to the Jaspersoft community edition download ×

daad.madhusudan

Members
  • Posts

    27
  • 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 daad.madhusudan

  1. The problem was in iReport field extractor. The solution for above problem is, we should analyse our stored procedure and create fields in iReport designer with the same name which are present in select clause of stored procedure. After creating stored procedure, just drag and drop the fields on the report are and execute it. It will show the retrieved data. This solution worked for me, so I am sharing it with you.
  2. I am working on a jasper report in which I have to make use of two different stored procedures say Test1() and Test2(). Normal syntax for calling stored procedure is: {CALL TEST($P{ORACLE_REF_CURSOR})} But for calling two stored procedure I tried in the followimng way: {CALL TEST1($P{ORACLE_REF_CURSOR})}; {CALL TEST2($P{ORACLE_REF_CURSOR})} ; But this doesn't work. Is it possible to call multiple stored procedures at a time? If yes what is the way to do this?
  3. I have written following stored procedure to test procedure call from iReport designer. Stored Procedure: CREATE OR REPLACE PROCEDURE test(cursor1 out sys_refcursor) IS BEGIN OPEN cursor1 for select person_id,first_name from person where rownum < 5; END; In my query window I am using following line to call this procedure. {call test($P{cursor})} where $P{cursor} is a parameter with class java.sql.ResultSet. I have added ojdbc.jar file into my class path and connection is also successful. When I run above statement for calling stored procedure it throws the error: Error: java.sql.SqlException:Invalid column type Can someone tell me what I did wrong here? AM i supposed to add any file or make any changes in the call to stored procedure?
  4. I have posted one question here: http://stackoverflow.com/questions/31933530/how-to-align-bars-and-corresponding-labels-properly-in-jasper-report Please help me to resolve this.
  5. Hi I am working on a jasper report in which I created a chart which looks like as given below: Here labels and respective bars are not alligned properly. Is there any way to achieve this?
  6. I am working on a jasper report in which I am using following SQL query: select SOURCE, count(*) as total from CASE_UPLOADS where UPLOAD_DT >= '20150601' and UPLOAD_DT <= '20150630' group by SOURCE order by SOURCE and the result is: SOURCE,TOTAL "New Application";15 "Periodic Report";16 "RD/RC";25 I have created variable like: <variable name="PR" class="java.lang.Integer" calculation="Sum"> <variableExpression><![CDATA[($F{source} == 'Periodic_Report') ? $F{total} : 0]]></variableExpression> </variable> This variable is printing zero value each time. If I change conditional clause as follow: <variable name="PR" class="java.lang.Integer" calculation="Sum"> <variableExpression><![CDATA[($F{source} == 'Periodic_Report') ? 0 : $F{total}]]></variableExpression> </variable> Then its printing SUM 56 of TOTAL column. Can someone please tell me what is wrong here?
  7. I am working on a jasper report which contains Pie chart. And the chart is occupying entire summary band. When I run this report the chart is compressed and legend box is taking almost more than half of the space. Chart looks like as shown in the image: Here is my customizer java class: public class DocumentUploadPieChart implements JRChartCustomizer { @Overridepublic void customize(JFreeChart chart, JRChart jasperChart) {Plot plot1 = chart.getPlot();if (plot1 instanceof PiePlot) {PiePlot piePlot = (PiePlot) plot1; Font font = new Font("Calibri", Font.PLAIN, 11); piePlot.setLabelFont(font); piePlot.setCircular(Boolean.TRUE); piePlot.setLabelOutlinePaint(null); piePlot.setLabelShadowPaint(null); chart.getLegend().setBackgroundPaint(null); chart.getLegend().setWidth(30); chart.getLegend().setBorder(0.0, 0.0, 0.0, 0.0); piePlot.setShadowPaint(null); } } } I tried to adjust width of legend but its still giving same output. Can someone please help me to resolve this issue?
  8. Thanks @sanbez for your response :). Yeah you are right. One person can have multiple race codes. In my case there are 7 race codes and one person can have many race codes from these seven values. So for this, I want seven digit binary representation. Want i want is: IF RACE_CODE CONTAINS (abc,lmn) then display 1100000 if RACE_CODE CONTAINS (abc,xyz) display 1000001 I am taking some test values here like abc,lmn,xyz for demo.
  9. I am working on a jasper report in that I am using a field "RACE_CODE" which contains values like 'abc','lmn','pqr','xyz'. For one person there can be multiple RACE_CODE assigned to it. So I want the output in term of four digits like: If a person have RACE_CODE 'abc' and 'xyz' then it should display '1001' and so on. I can use conditional statement like: $F{RACE_CODE} == 'abc' && $F{RACE_CODE} == 'xyz' ? '1001' : ($F{RACE_CODE} == 'abc' ? '1000' : so on But this is not a feasible way because for four digits I will be having 12 combinations. Is there any other way in which I can achieve this? Please help to solve this.
  10. I am working on a jasper report in which I am using two input dates "START_DATE" and "END_DATE". I want to keep default value for START_DATE as "2013-12-01' and FOR "END_DATE" as current date. For END_DATE I am able to do it using expression "new Date()". But for START_DATE how can I specify this default value. I tried top do it like: new SimpleDateFormat("yyyy-MM-dd").format((new SimpleDateFormat("yyyy-MM-dd").parse("2013-12-01"))) But its throwing error: Error filling print... java.lang.String cannot be cast to java.util.Dat Please help me to solve this.
  11. I am working on a jasper report which takes two input date parameters from user as START_DATE and END_DATE. I want to put validations on these dates like: 1) END_DATE should not be less than START_DATE 2) START_DATE should not be greater than END_DATE 3) END_DATE should be max upto 30 days after START_DATE (difference between START_DATE and END_DATE) should be max 30 days Does anyone know how to to it using ireport? Or is there any alternative way to achieve this in jasper server?
  12. Hi, I am working on a jasper report which has total 15 requirements and all these requirements should be included in a single jasper report. Report contains tables and charts. What I planed is I will keep all tables in detail band and all charts in summary band. But still I can't add all requirements in siongle report. Tables I can fit in detail band, but for chart I can,'t reduce the charty size as individual chart has useful data and it should occupy full width of summary band. And I have 6-7 charts. Is there any way we can adjust the height of summary band as per our need. I tried but I could increase it till max 802. Please give me solution for this.
  13. I am working on a jasper report and I am generating a chart with the following data: reason count A 10 B 27 C 45 D 35 Now instaed on displaying labels I want to change it like For 1st retrived reason label will be "Reason 1" for second "Reason 2" and so on. These labeling will be independent of reason codes mentioned in the output data. Is there any way to set these labels using customizers like reason[0] = "Reason 1", reason[1] = "Reason 2"? Please help to solve this problem
  14. I want to display following data in my report: number of hits on a website from particular date to current datenumber of access to site from different browsernumber of new visitors and unique visitors and returning visitors.I will use google analytics to get this data. But How can I get this data to generate the report? Is there any way to get data from google analytics into ireport designer?
  15. in parameter expression clause add following line: new SimpleDateFormat("yyyy-MM-dd hh:mm:ss").format($P{Date}) I think this will work
  16. I am working on a jasper report which generates a 3D piechart as shown below: but I want my report to look more like side look of a disk as shown below: Is there any way to do this?
  17. I got the solution for this. I added following two lines of code in my customize methos: piePlot.setLabelOutlinePaint(null); piePlot.setLabelShadowPaint(null); And this removed box around labels :)
  18. I got the solution. Using depth field in ireport designer, we can adjust the thicknes. For me I kept it 0.08 and graph generated in the disk format.
  19. I am working on a jasper report which generates a 3D piechart. The thickness of pie chart is very large. Is there any way to reduce it using chart customizer?
  20. I am working on a jasper report which generates a bar chart. My chart looks like this: I am putting labels on top of bar using this line of code in my customizer class: categoryPlot.getRenderer().setBasePositiveItemLabelPosition(new ItemLabelPosition(ItemLabelAnchor.OUTSIDE12, TextAnchor.BOTTOM_CENTER)); Now I want to increase the gap between top of bar and labels. How can I achieve this?
  21. I am working on a jasper report which generates pie chart. In this chart, labels are surrounded by rectangular box with black color border. Is there any way to remove these boxes around the labels? I am able to remove the box around chart using expression: chart.getLegend.setBorders(0.0,0.0,0.0,0.0) But I don't know how to do this with labels. Can someone please help me on this?
  22. I am not very sure but I heard about page break concept that can be used here. Please have a look at this: http://stackoverflow.com/questions/8069462/how-to-insert-a-page-break-in-jasperreport
  23. I got the solution :) In my customizer class I am adding following lines: CategoryPlot categoryPlot = (CategoryPlot) chart.getPlot();categoryPlot.getRenderer().setBasePositiveItemLabelPosition(new ItemLabelPosition(ItemLabelAnchor.OUTSIDE12, TextAnchor.BOTTOM_CENTER));Its working :)
  24. I am working on a jasper report and I am generating a bar chart. What I generated using ireport designer and customizer(to show labels) is: Here I want to show the labels outside the bars. How can i do it? Is there any way using customizer? Also for second bar because of small size label is not visible, in this case what can I do?
×
×
  • Create New...