Converting multpile rows per patient to one row per patient

Leeanne2

New Member
Joined
Feb 5, 2019
Messages
2
Hi,
I have a table of patients and their diagnoses where eachline contains a separate diagnosis and there can be many lines per patient.
I need to convert this to one row per patient with all ofthe diagnoses ordered Primary 1 diagnosis code, Primary 1 DiagnosisDescription, Secondary 1 diagnosis code, Secondary 1 diagnosis description,Secondary 2 diagnosis code, Secondary 2 diagnosis description, and so on till Irun out of codes and descriptions – sometimes this is lots.

I have an example of how I have done small datasets using vlookups but thisdoesn’t easily translate to massive datasets. I’m keen for advice on a better way to achieve this.
 
Last edited by a moderator:

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.
Sorry about the picture - I don't know why it didn't post correctly and a don't have the permissions required to go back and edit the post to remove the image. hopefully someone who can will delete it for me!
 
Upvote 0

Forum statistics

Threads
1,215,831
Messages
6,127,144
Members
449,363
Latest member
Yap999

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top