Crystal Reports 2016 - How to display multiple tables? - crystal-reports

I am actually stuck with a multiple tables problem. I want to display 2 tables in my report.
I saw how to do it with C# but I am not using C#, only Crystal Reports. So I have to manage to do it inside Crystal Reports. Is there any way to do it other than use 2 sub reports?
Because from what I understood (I am very new to Crystal reports): to make a table, you have to put the header of the columns in a Header section and the datafields in a Details section.
But when you create sub groups, you can't add Details sections to each group, right?
What I want is something like that:
Example of what I need
How should I organize my report (in the section expert) to manage such a thing?
Thank you very much to anyone that can help!

You may be overthinking the details sections. When you group data in Crystal Report you get a Header and Footer section for each grouping level. So if you have 3 grouping levels, the report has the following sections.
Report Header
Page Header
Header 1
Header 2
Header 3
Details
Footer 3
Footer 2
Footer 1
Report Footer
Page Footer
In this report layout the details section contains detail records for Header 3 data. The data for Header 1 is detailed in Header 2, and the detail for Header 2 is found in Header 3.
The table layout you want to use is probably going to require at least 1 subreport. You may be able to pull the data for the first table along with the report data that is a higher level than tables, but you may need to do 2 subreports to prevent duplication of the data. I would focus on getting each table working in individual reports first, then you can link them into another report as subreports once you have both tables displaying the way you would like.

Related

How to use a report as subreport (with additional info) multiple times in a maintainable way?

So basically I have a report. I need this report to be printed as a 'set of reports'. Except that for each time the report is printed, there has to be a specific numbering at the bottom of the page. Where it would look something like this:
Page 1: Report + Page footer text 'Number 1'
Page 2: Conditions
Page 3: Report + Page footer text 'Number 2'
Page 4: Conditions
Page 5: Report + Page footer text 'Number 3'
Page 6: Conditions
And so on, for an undetermined amount of times..
In order to achieve this, I have created a main report, which currently contains 20 subreports, in order to achieve 20 pages (but I really I'd like this to be dynamical, maybe to be able to set the number of copies or something). Where each subreport consists of the single mentioned report (through the subreport 'Choose an existing report' option), with a custom text at the bottom.
The problem with this is that I can't maintain this. Every time an adjustment needs to be made to the original report, I will need to access 10 subreports and make the very same change or reload the report into this subreport.
What alternative ways of achieving my goal can you suggest, because this feels really 'dirty'. Thank you for reading.
I run Version 14.0.2.364 of Crystal Reports 2011
To achieve this, you need to use group and detail section in main report. For making adjustments with paging, each section has his own
page before
page after
reset page
So to help you a bit, you need to have your data in one datasource, and group by
Report/Conditions. For each group you can have only 1 subreport which will have link for that specific subreport (e.g. where barcod of smth is 1234) and there show your subreport data. For page number i would advise you to use my approach (for grouping) and then for page number you display group number (and that solves you all formulas for calculating pages).
If you are not familiar with grouping in Crystal, you can group your records in report by some fields by following image below
To summarize, try to define by which fields your reports has 20 subreports (probably some keys from database) and then group by that fields, examine advances of section expert and paging and you should be done in few hours making your report readable and easy to maintain.
Hope it helps

Crystal report - displaying details and report header in a same row

I have a requirement in crystal report, where we have to show details section and report header together, so data will be displayed in a same row and according to the input the detail section can also grow in both direction row wise and column wise. Please use the sample picture for reference.
Is there any way to keep them together like in HTML where we can divide any table into one or more columns?
Any kind of information would be appreciated. Thank you.
In crystal it is not possible to add detail section in report header part..
How ever you can split detail section to multiple layout!!
1 - Right click report body then select Section Expert.
2 - Select multiple column.
3 - Then on layout you can provide detail size and gap detail.
Also you can insert multiple detail section and can swap inside the detail section. but not in report header part
It is possible for this purpose you need to use sub reports.
create a sub report and place in header section. Now limit the width of the sub report to the extent you need.
In sub report place the fields in details and supress rest all sections.
Now you can see header and details in report header..
Can you share along with sub report what you want to view in header?
You can use sub-report or setting up the section expert option.
Go to section expert
step 1: Suppress page header
step 2: At report header mark Underlay Following Section
Section Expert

Ireport 4.0.2 band layout multiple column headers and footers

Is it possible in Ireport to have a band layout like the one below without using subreport? Or is there any other workaround. I tried to use subreport but unfortunately I cannot solve my issue. These have separate queries and I use php to fill in data to each details. Please help me.
Column Header 1
Detail 1
Column Footer 1
Column Header 2
Detail 2
Column Footer 2
Try to use Table elements in your report. You can use there the same dataset too.

Crystal Reports Cross Tabs Growing Into Each Other

I have a report with several crosstabs in the report header. The problem is that some of them grow down into the ones below them. Is there an option to have each crosstab dynamically determine its starting position based on the end of the previous one?
create multiple report header sections and put one crosstab in each

Page header & footer on Summary band

I have read this thread:
http://jasperforge.org/plugins/espforum/view.php?group_id=83&forumid=101&topicid=67923
I would rather not repeat the page header and footer for each crosstab, as there are six of them, and if the header needs to change, I'd like to change it only once.
The problems include:
Putting the crosstabs on their own page (should be easy enough with a page break).
Making the crosstabs include the same header and footer as the rest of the report.
Reusing the header & footer from a single source.
Making the crosstab be shown before the data (not all that important, but would be nice).
The report appears as follows:
It would be fantastic to have the crosstab appear on a page by itself, including the same header and footer as the rest of the report, rather than looking like the image above.
The report is set up as follows:
Any ideas?
The solution involved these changes:
Provide a dummy query for the main report (e.g., SELECT 1 FROM DUAL)
Create a new subreport for the data details, based on the former query for the main report
Add a second detail band (Detail 2)
Place the six subreports in the first detail band (Detail 1)
Place the data details subreport in the second detail band (Detail 2)
Pass the parameters from the main report into the data details subreport
Reduce the data details subreport's margins to zero
Delete the Summary band (no longer required)
This allows full control over the crosstab's report position while reusing the same header and footer for both the crosstab and the data details.