Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Merge Rows Post Reply Post New Topic
Author Message
mrdaddysmith
Newbie
Newbie
Avatar

Joined: 29 Jan 2013
Online Status: Offline
Posts: 2
Quote mrdaddysmith Replybullet Topic: Merge Rows
     Posted: 03 Mar 2013 at 10:21am

I need to produce a report that shows the name of the person administering a case.  This is fine, but in some occasions there may be two people administering the same case at the same time.  In this instance I need to show both names in the same row, but cannot seem to get this to work.

The data required is pulled from three fields – {Administrators.Number} (which can either be 1 or 2), {Case.Reference}, and { Address.Name}.

So to pull Administrator 1’s details I have the following: If {administrators.Number} = 1 then {address.Name}  else “ “

And for Administrator 2’s details I have the following: If {administrators.Number} =2  then {address.Name}  else “ “

This produces the following (a history of all previous Administartors):

CaseRef                 Admin1                  Admin2

01                           person a             

01                                                          person c

01                           person b             

01                                                          person d

 

I need to show the last administrator 1 and 2 where there is no null value:

 

Case Ref              Admin 1               Admin 2

01                          person b             person d

 

I have tried grouping by case ref but get the following result:

Case Ref              Admin 1               Admin 2

01                         person b             

01                                                       person d

 

Any help would be appreciated.

IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 04 Mar 2013 at 4:21am
Not sure I understand your Data set up. Do you have admin 1 and admin 2 on the same row of data? if so, you need to add administrator and address table each twice to the report. Join each to the respective instance of the admin one and admin 2 fields. then you just pull the name from each of the version of the table (address.name and address_1.name

Edited by DBlank - 04 Mar 2013 at 4:22am
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum