Solved

Limit Detail Rows Per Group in a Crystal Report

Posted on 2013-06-06
3
1,185 Views
Last Modified: 2013-06-06
Hello All,
I have been asked to create a report but to only select the Top1record per group. Example I have grouped by drug and need to restrict the report to only select 1 dr attached to the drug. Any help with this will be greatly appreciated.
Thanks.
0
Comment
Question by:Star79
3 Comments
 
LVL 77

Expert Comment

by:peter57r
ID: 39226298
Do you have a rule for choosing the one record you want or would it be any record in the group?
0
 
LVL 22

Accepted Solution

by:
Ido Millet earned 500 total points
ID: 39226307
Simplest option is to simply drag the info into the Group Header. The group header always shows the info for the 1st record in the group.
Then, suppress the detail section.

You just need to sort the records within the group such that the 1st record is the one you are interested in.

Similar logic applied to the Group Footer (shows the last record in the group.
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 39226371
Agree with Ido.

There is also an option with groups (GROUP SORT EXPERT) for a TOP N report

mlmcc
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Crystal Report Date Range Parameters 2 52
Crystal  - Shared vairable capture wile printing 1 35
Pagination Difference  in crystal report 7 43
Mask on Parameter CR2008 28 43
Crystal Reports: 5 Tests for Top Performance It is complete, your masterpiece report.  Not only does it meet your customer’s expectations, it blows them out the water, all they want is beautifully summarised and displayed in a myriad of ways. …
I hate sub reports and always consider them the last resort in any reporting solution.  The negative effect on performance and maintainability is just not worth the easy ride they give the report writer.  Nine times out of ten reporting requirements…
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now