+ Reply to Thread
Results 1 to 2 of 2

Convert Repeating Fields (Columns) to Rows

  1. #1
    Registered User
    Join Date
    03-19-2012
    Location
    Buffalo, NY
    MS-Off Ver
    Excel 2010
    Posts
    4

    Convert Repeating Fields (Columns) to Rows

    I have an Excel problem that I hope someone can help me resolve. I have an Excel data export from a clinical radiation system. There is one row per patient in the export and each patient could have received one or more radation treatments.

    The problem I have is that there is one horizontal row for each patient regardless of how many treatments they recived. The fields are repeated in that row with an appended number (A1_1, A1_2, A1_3
    ...) for each successive treatment. The first 2 fields are not repeated - SubjID and ProtocolID.

    What I would like to do is have a seperate row (record) for each time there is a new treatment for a patient. The SubjID and ProtocolID would always be the same for each unique patient.

    So the question what can I do to put all that horizontal data into individual rows?

    Sample Excel column structure:

    SubjID, ProtocolID, RadiationType_A1_1, TSSPatientID_A1_1, TotalDose_A1_1, RadiationType_A1_2, TSSPatientID_A1_2, TotalNoFractions_A1_2, RadiationType_A1_3, TSSPatientID_A1_3, TotalNoFractions_A1_3,

    Thanks for any suggestions you may have,
    Ken

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Convert Repeating Fields (Columns) to Rows

    Could you upload a sample workbook with a few records, and also manually create the result you expect to see. These things are always easier if we can see the request in context. Anonymise any names if necessary.

    Regards
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1