Composite reporting, Crystal Reports difficult to manage - crystal-reports

I was wondering if someone had a suggestion on how to best do composite reporting.
I have tried to accomplish this with Crystal Reports [CR] (The one that comes with VS2k8) but for a codemonkey like me, it's hard to grasp the design part...
I have found that CR works nicely for reporting on tabular and repeatable data, but I can't grasp how to do what I want it to do.
What I want is a nice front-page, with title, subtitle and possibly some other text.
Maybe a TOC.
A summary report, consisting of some calculations and text-summaries calculated beforehand (not using the reporting tool).
Then a listing of one type of data, normal tabular.
Then another type of data, also tabular.
Then a drill-down on the first type of data. (Every "line" in the first type has 1..* associated items).
It looks to me like I have to do them all in separate reports, then "concatenate" the resulting reports to one another to get one report. And the front-page and the summary page I have no idea how to do at all.
Is there a better tool for doing this? Or does anyone have a good "quick-start" on composite reporting with CR? :)
EDIT: Oh, and these will only be used in printed-form. So no dynamic drill-down and such are necessary.

I create sub-reports and insert them into a footer section of the main report to create composite reports, using seperate reports as you suggest. I've searched myself, and failed to find any reasonable alternative. This approach works well enough and results in a single report file when done.

In my experience, Crystal is a pain in the butt for doing anything like a fixed page layout (ie: the title page). I usually put the title page in the report header (make sure to select "new page after" in the section options). Everything else pretty much has to go into subreports.
If you need to share totals and such between subreports, you need to use a shared variable in a formula field:
shared numbervar whateverTotal:= sum({whatever});
and then in the following reports, just use:
shared numbervar whateverTotal;

Related

Display multiple columns in a group header with charts

I want charts generated for each group to appear in a multi-column format in one group header. I could do it with subreports, but I'm looking for a solution that doesn't require me to load the data set multiple times. How can I achieve this?
Long story short, Crystal isn't a good fit for this.
Even if the number of groups wasn't variable, Crystal reports is fixated on delivering and iterating your records from top to bottom. It's not impossible to structure that, but it would be way more work than it's worth. Plus you'd waste too much time handling the variable number of charts and ensuring unused ones were suppressed. And even then, you'd probably need to use subreports.
You'd have better luck using something other than Crystal for generating this behavior. Even if it meant creating a subreport for the chart and writing a VS program that displayed that report multiple times for each "Group".

Collect all data from Crystal Report

I have a crystal report containing multiple subreports. I need to find the way to 'collect' all the data printed on the report/subreports in the following (or similar)
format:
Page1:FieldName1=Value1|FieldName2=Value2|...|Page2:FieldName1=Value1.1|FieldName2=Value2.1|.....
So, the important note is that there is a possibility to figure out on which page (in the PDF generated from report) the particular field value occured.
I tried to do some complex formulas which would 'remember' all the data in a cumulative string within formula(s) (WhilePrintingRecords) but the part I can't achieve is to associate each value to correct Page number of the main, top level, report (the page numbers are of crucial importance in this purpose).
The problem is even more complex because of the groupings and linking applied in main report and subreports, so the Page numbers is at the end of the printing kinda changed comparing to design time order.
Can anyone come up with any idea please?
Thank you Siva, your reply led me to another thing to investigate (I'm new to Crystal Reports) - the issue was actually not related to incorrect execution of the formula keeping the page counter, but rather the one more formula I thought was not executing, since I didn't know that if formula is in the section which is suppressed (and hidden) IS STILL EXECUTING. The counter always counted one more page which was sufficient. When I removed that formula that I didn't need - it worked just fine. So, it was my fault :(

Crystal Reports : Crosstab refuses not to paginate

I am using Crystal Reports 11 (XI) and I have a crosstab that has quite a few rows to it. Its publishing format is to Excel, so pagination doesn't really even make sense. However, no matter what I do it repeats the column/crosstab headers every couple dozen lines. I've tried:
-Increasing page size definition to max size (12x18) portrait
-Turning off pagination in the output settings
-Turning off horizontal pagination
-Deleting column headers (works) but I cannot delete the crosstab header
I'm running out of ideas.
If the goal is just to create an excel file with some pivoted data crystal reports is not the best way to do it. Check the first 5 minutes of this video:
http://www.r-tag.com/Pages/Preview_Demo.aspx
It compares the same data presented as a cross-tab in Crystal reports and pivot report based on a SQL ad-hoc query. SSRS is also part of the comparison and it is a better choice than Crystal too , but SQL ad-hoc query is my favorite for pivoted data.
P.S. I am proposing this alternative because the tool is free, it will save you development time and will create a better formatted excel file. If you are using BOE and you want to keep the report there this might not work for you.
The solution is as contrived as the problem...
There is no way in Crystal XI to "turn off" the crosstab pagination. It simply cannot be stopped. However, you can cheat the system by configuring a massive page size. In windows on your development machine, locate your XPS printer virtual device and choose "Print Server Properties" (in the top banner in Win 7+)
In the "Forms" tab, you will be able to configure a new paper form object of arbitrary size. Click on "Change Form Settings" and create a new page that is as large as you think you will need. I'm not aware of any limitations on this configuration, but I'm sure bad things happen if you go nuts.
Returning to crystal, go to printer configuration and select the XPS document printer as your target device for exports, and save the custom page size as the target paper type.
Now, the crosstab will assume you are printing to a massive sheet and will not attempt to paginate. As far as I can tell it's impossible to achieve the same effect any other way.
Here is a introduction about jasper crosstab.
http://www.tutorialspoint.com/jasper_reports/pdf/jasper_crosstabs.pdf
From the document, you can add two attributes in node
<crosstab isRepeatColumnHeaders="false" isRepeatRowHeaders="false">
...
</crosstab>

Crystal Reports : This group section cannot be printed

I'm currently modifying an existing report and replacing the data source used in the report. The reason I'm not creating a new report is because the report is laid out exactly how I would like it to be laid out. I've updated every field with the new data source fields and checked that the formulas are all correctly formatted.
Everytime I attempt to view the report (I'm using the Crystal Reports tool in VS 2010), I get the error "The group section cannot be printed because its condition field is nonexistent or invalid. Format the section to choose another condition field."
I've read another question from stackoverflow but still can't seem to find out what is wrong with my report.
First of all, why doesn't Crystal tell you more specifically what is wrong?
Any suggestions or hints?
My first thought is that you didn't update the Groups correctly when you switched backends. Go into your Group Expert. Do you see any groups simply labeled with question marks? If so, there's your problem. Go into the options for that group and choose an appropriate grouping field.
Also, use the Database->Verify Database command to look for other possible errors.
As for your question about Crystal's design, I believe that it does give reasonably accurate error messages, especially considering everything that can go wrong with any one report.

SSRS 2008 - Expand and Collapse subreports

I am dealing learning SSRS 2008. I want to do a report that is a little bit more complex.
I would like to have a row with information about "Object": name, id, description, etc. And I would like to have a + sign in this row, so I can expand/collapse rows that are regarding "Comments" about that object, with columns like "comment", "date", etc.
I first tried the "Grouping" approach, but I got to a dead end because the groups would use the same header.
Now I am trying to tackle it with a subreport.
The first problem I had is that I couldn't find the query designer in VS2008, so I started the SQL Reporter Builder.
Is there any way to use the Query Designer inside VS2008?
Then I created my report and my subreport as different report files, because I thought I would be able to use the subreport properties to select the subreport file and add it, but I was wrong. How can I add it? Do I have to publish it?
I just found out that I can't use the rdl file from SQL Report Builder in Visual Studio (it doesn't recognize the file extension, in VS2008 it is rdlc).
I am basically lost.
Could someone give me some guidance?
Thanks,
Oscar
This was asked a while ago but you haven't closed the question so I assume you still need an answer.... Are you looking to add the drill down feature to your report?
http://blogs.lessthandot.com/index.php/DataMgmt/DataDesign/creating-a-basic-drilldown-report-in-ssr-2005
http://www.sqlservercurry.com/2009/08/creating-drill-down-report-with-sql.html
If not... I am confused at what you are looking for and if what you want is really intended to be done in SSRS.
And... are you using subreports because the Object information and the Comment information is on different servers or data sources? Because it seems like you would want to use grouping for this, and group by the objectID and have the comments below.