Does BIRT support unrelated datasources for one report? - birt

I have a report which needs to be rewritten in BIRT (currently implemented in crystal).It contains subreports that are completely unrelated to each other. E.g price info is one subreport and dependent info is another subreport. Both of these have no column in common.
Each of the subreport invokes its own SQL and hence has its own result set.Is it possible to have such unrelated datasources in BIRT?
I have to use XML as datasource.
Thanks in advance!!

Related

How to improve DB load produced by SSRS reports

I would like to know whether there is a posibility to reduce the DB load produced by SSRS reports.
I have a SSRS report consisting of several sub-reports. Every one of them has at least one DB query.
Many of them query the same data since the most sub-reports have a kind of template header filled with dynamic data.
Some sub-reports are shown depending on whether a query returns any data. So once the data is queried to determine whether to show the report at all. Then the report itself queries the same data to show it in a table
In general I can tell that I need a mechanism to pass queried DB data from parent report to a sub-report. The parent report will query some data, it will iterate over the data sets and for every data set it will show a sub-report passing the current data set as a parameter.
I could not find a mechanism to pass the data set (data row). That's why I show the sub-report by passing a kind of data set ID. The sub-report itself queries the same data again, filters by the passed data set ID and shows only the relevant data set. This causes huge load on the DB.
Thank you in advance!
The design you describe is fairly standard and I would not expect it to cause "huge load on the DB". I would expect the DB load of running 10 filtered sub-reports to only be about 10-20% more than running one report covering the same 10 items.
I would add an index on the "data set ID" column to make that filter more efficient.
Depending on complexity of your subreports using lookup function may be an acceptable faster solution. And previous comment about hiding rows or subreports with no data applies here too.

Crystal Reports 2008 - parameters from selection criteria are not being used to select to retrieve data from db

I have some reports written in Crystal 2008 using business views. These reports have a date parameter set up and I have a selection on the date defined in the select expert. However, when I run the report it appears to retrieve all the data from the database and only then filter out based on the date. As you can imagine this slows down the report quite a bit. I also clicked on Database-Show SQL Query and confirmed that the date parameter did not appear in the SQL Query. This behavior seems very strange to me. This did not use to happen to me when I used Crystal 8.5 with dictionaries. Is this a limitation using business views?
I did some searching and found that I can create a report using a database command. This helped improve performance on one of my reports but when I tried to do something similar on a different report, even though I was using the database command, it still did not appear in the appear to be doing the selection on the database before retrieving the data and the report took forever to run. I also didn't see the selection in the SQL Query.
Do I need to add the parameter to the database command? Will I be able to prompt the user to enter the value when they run the report?
I hope there is a way to do this properly using business views because otherwise I'll have to rewrite all my reports to use another method.
Any ideas or advice are welcome. Thank you very much!
I had a similar problem. I used the command, but my report was still taking longer than i had hoped to run. so i added a where statement into the command to start checking dates starting from 2009. that sped up my report a little.
you may want to consider creating a stored procedure if you think you are pushing CR to the limit. that may also help sped up the report.
I figured out what the problem is. My business view had fields in it that were formulas. If you try to use selection criteria using a formula, it does not add the criteria to the WHERE clause in the SQL Query. Luckily, I was able to find other fields besides the formula in the business view to do the selection.

Problem in rendering chart in BIRT when adding dynamic series with scripted data source

I am creating a BIRT report which will contain chart which has been bound to a Scripted Data Source. I need to add series to this Bar chart on user request and hence I started following the below example.
http://birtworld.blogspot.com/2008/10/dynamically-adding-series-to-birt-chart.html
First I tried to run the exact same report(in the above page) in my deployment environment and it ran perfectly. Then I kept the main logic intact and replaced the Sample database with a custom Data Source. When I try to run this report in the same way, all I end up having is a blank page with no chart rendered.
I tried to put in logs at the appropriate places and found out that my datasource has been called and the collection has been initialized and is being returned to the BIRT report. But the part where the chart should have (in my opinion) filled the DataSet (which is connected to the chart) was not called.
Can anybody please point out as to where am I going wrong.
For the related attachments, Please have a look at http://www.birt-exchange.org/org/forum/index.php/topic/21486-problem-in-rendering-chart-when-adding-dynamic-series-with-scripted-data-source/
I'm sorry I can't have access to the links you're refferring to.
However, the lack of results in your reports is generally caused by the lack of data to use.
Since you changed the data source, are you sure that the datasets are still fetching the same information? (are the output columns the same as with the example for each dataset?)
If it's not the case, you will have to either modify the aliases of your output columns in order to match the ones used in the example.
Or, you'll have to adapt every rendered object (remove every entry and refresh the data binding of every object, and update the values you're using as well).
Hoping this will help.

Defining transaction isolation in BIRT

My BIRT report retrieves data using a SQL query (JDBC datasource). My SQL Server 2005 database
is set to use snapshot transaction isolation.
How do I define the transaction isolation mode in BIRT report designer ?
Programatically it's done calling the datasource method setDefaultTransactionIsolation(4096) (4096 means snapshot isolation).
You handle this in the Data Source properties. After successfully creating your data source in BIRT, double-click it to edit it. Select the "Property Binding" grouping on the left of the editor. You will see a property there called "Isolation Mode". For SQL Server, you would add "SNAPSHOT".
A cool feature of BIRT actually allows this property (and all others on this screen) to be parameterized. Click the formula editory by the text box. There you can either bind the value to a report parameter (this is the most common apprach) or implement some logic to determine the desired value. This give you even more flexibility in case the requirements of the underlying data stroe shift. If/when that happens you will not have to edit your design, only alter the input parameter.

Reporting Services Client side

I need to compose a report using multiple subreports, "chained" together at runtime in a C# Forms project.
The subreports each represent a subtest of a product, and the data needs special formatting to make sense to the report users ( Special graphs, sensible column names with/without engineering details etc )
I Imagine that every Subreport has a subreport field so that I at runtime can insert the next subreport into. Obviously the first (main) report has a subreport as well, and a finalizing subreport does not (summary subreport)
Is it possible to build chain subreports together at runtime ?
Does anyone out there have a sample?
Kind Regards
Jes
I imagine this is possible with the Reporting Services product, but I don't know how to do it. In our experience as part of the ActiveReports team, we've found that subreports are also not always the most performant and memory efficient way to accomplish this.
For information about how we suggest to do this with our ActiveReports product see the following explanation:
http://www.datadynamics.com/Help/ActiveReports6/arHOWInsertOrAddPages.html
Scott Willeke
GrapeCity - Data Dynamics

Resources