csv - Jaspersoft Studio : issues while drawing graph -


I am new JasperReports / JasperSoft Studio and conflict one It can be very primitive for experts with a bit chart and it is possible that I can lose some basic things here. Here is a brief description of what I am trying to do
1) Data source is CSV with the following areas.
Sr_No, URI, total_time_taken, no_of_requests, avg_time_per_req, most_expensive_req, timestamp_of_exp_req
2) In CSV around 40,000 lines it is 3/12/1) I want to make (A is a report which has all 40,000 lines in it, Simple column report based on all fields, sorted by no_of_requests in descending order) JasperStudio is a piece of cake!
4) After this, I want a summary page with a "Top 10" URI in a pie chart where the value of the pie series is no_of_requests and the key URI (pretty straight forward)

I want Jaspar A report has been prepared in the form of CSV with the data source in the studio. I have selected all the fields and have not applied any filter for my query for the primary dataset (i.e. the default dataset similar to me when creating the report). It helps me to print all 40,000 lines in the "Description" band of the report ... so the first part is kept in mind.

For the summary page, I need a pie chart where my challenge is to record the "Top 10" record from the entire dataset that my "Top" criteria is based on the no_of_requests field and my data is based on that area Has already been sorted. Even so, I need a subset of data to make a meaningful chart, to achieve this, I tried to create a new dataset with just two fields, the URI (the key of the pie) and the number_off_request (which is the value is). I also applied filter expression "($ V {REPORT_COUNT}> New Integer (10)) False: True" for my new dataset so much that I get the "Top 10" record from my already ranked data I've verified that the filter is working properly by running it in the "Data Preview" tab of the "Dataset and Query" dialog. I have selected the new dataset for my pie chart as "Dataset".

When I run the report (I have 40.00 lines printed correctly (in preview mode of JasperStudio) Bands in details) but summary is empty. It does not draw any of the pie charts. I tried with a chart once, but the result is the same. The summary of that case only shows X and Y axis, which does not have any data point. The graph is empty.

Am I missing something?

Any help in this regard will be highly appreciated.

I have created two variables, in my pie chart to select the top N value from the dataset I am using. To get this, I used the $ V {REPORT_COUNT} variable as follows

IF ($ V {REPORT_COUNT} & lt; = N, $ F {Your_Field}, "") - If the variable is a The string is IF ($ v {REPORT_COUNT} & lt; = N, $ F {your_Variable}, 0) - If the variable is integer.

Option N with your desired number. If you need the top 10 value then N = 10

Now I have used these two variables to create my pie chart .

I have written a blog for it, because I could not upload images here.

Please check the same for a detailed solution.


Comments