We help IT Professionals succeed at work.

How do I group information from multiple rows of the same PatientID?

Kevin
Kevin asked
on
Hello,

I am using Crystal Reports v12 with a spreadsheet as my data source.

In my spreadsheet I have a few rows which contain the same PatientID. I am trying to group some of the information together for the rows with the same PatientID, but cannot figure out how to do this.

Is someone able to advise how I can accomplish this?

See attached as an example:

data
Data.png = Sample data from the spreadsheet.

PatientID-5454
PatientID_5454.png = Sample of expected results for patient ID 5454 showing insertions.

PatientID-4522
PatientID_4522.png = Sample of expected results for patient ID 4522 showing insertions, mainly the three (highlighted in yellow) from the spreadsheet.

Kindly advise.

Regards,
N
Comment
Watch Question

Senior Consultant
Most Valuable Expert 2011
Top Expert 2013
Commented:
Crystal does support groups.

Click INSERT  --> GROUP
Select the Patient ID field for the group
Put the common information in the group header
    Patient ID, Name and fate
Add the header for the details
     Dental Work
Put the details of the work in the detail section
    Dental work and cost fields
Put the sum of the cost field in the group footer

mlmcc
KevinInformation Technology

Author

Commented:
Thanks mlmcc, but can you be more specific please on how to get to these places.

I am stuck from here:

*Put the common information in the group header.

Do I do this in the format editor of the group for the object name?

Please be descriptive.

Kind Regards,
N
Mike McCrackenSenior Consultant
Most Valuable Expert 2011
Top Expert 2013

Commented:
No.  Just drag and drop them into the header section.  You may need to make the group header taller.

mlmcc
KevinInformation Technology

Author

Commented:
mlmcc its still showing only one entry on each page for the dental work.

Maybe I am doing something wrong.

Can you provide a more descriptive step by step guide please?
Mike McCrackenSenior Consultant
Most Valuable Expert 2011
Top Expert 2013

Commented:
Can you give me  a screen shot of the report in the designer?

Do you get all 4 records in the report?

Do you have NEW PAGE BEFORE or AFTER set on any sections?

mlmcc
KevinInformation Technology

Author

Commented:
mlmcc,

Please see below. Also note that I have no idea where to check for the NEW PAGE BEFORE or AFTER, so i am assuming that both of them are disabled.

design
preview
As you can see from my screenshots it's a complete mess.

Kindly advise what I have done wrong, and please provide step by step instructions on how to fix.

Regards,
N
KevinInformation Technology

Author

Commented:
mlmcc, I figured out what I did wrong. But your solution definitely got me on the right track.

Thanks.