+ Reply to Thread
Results 1 to 7 of 7

re-arranging data

  1. #1
    Registered User
    Join Date
    02-03-2019
    Location
    riyadh
    MS-Off Ver
    Office 365
    Posts
    23

    re-arranging data

    hi all..

    please help in re-arranging data. i post picture below for my work. i also attached the excel file.

    i tried using pivot, but im not getting what i need..

    thank you.

    Attachment 651506
    Attached Images Attached Images
    Attached Files Attached Files

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,635

    Re: re-arranging data

    Please update your forum profile with the version of Excel that you are using - what is pictured is definitely not from 1997!
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Registered User
    Join Date
    01-23-2014
    Location
    Calgary, Alberta
    MS-Off Ver
    Excel Office 365
    Posts
    32

    Re: re-arranging data

    I don't understand what you're trying to accomplish. can you clarify and be specific in your expected results please?

  4. #4
    Registered User
    Join Date
    02-03-2019
    Location
    riyadh
    MS-Off Ver
    Office 365
    Posts
    23

    Re: re-arranging data

    hi LouisTh.. i am given the table on the right, where the data is arranged horizontally. I need to re-arrange the data in vertical format, such as the table on the left. I am working with 20,000 sites and i need to re-arrange data for upload.

    Thanks!

    Attachment 652273
    Last edited by AliGW; 12-02-2019 at 01:49 AM.

  5. #5
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,997

    Re: re-arranging data

    Try this:

    A3:
    =IFERROR(INDEX($F$3:$F$5,MATCH(0,INDEX(--(COUNTIF($A$2:A2,$F$3:$F$5)=$G$3:$G$5),0),0)),"")

    B3:
    IF($A3="","",OFFSET(INDEX($F$3:$F$6,MATCH($A3,$F$3:$F$6,0)),,2+2*(IF($A2<>$A3,1,B2+1)-1),,))

    C3:
    =IF($A3="","",OFFSET(INDEX($F$3:$F$6,MATCH($A3,$F$3:$F$6,0)),,3+2*($D3-1),,))

    D3 (helper - which can be hidden, moved, or even be on another sheet):
    IF(A3="","",IF($A2<>$A3,1,D2+1))
    Attached Files Attached Files
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: L? fh?ile P?draig sona dhaoibh

  6. #6
    Registered User
    Join Date
    02-03-2019
    Location
    riyadh
    MS-Off Ver
    Office 365
    Posts
    23

    Re: re-arranging data

    Quote Originally Posted by Glenn Kennedy View Post
    Try this:

    A3:
    =IFERROR(INDEX($F$3:$F$5,MATCH(0,INDEX(--(COUNTIF($A$2:A2,$F$3:$F$5)=$G$3:$G$5),0),0)),"")

    B3:
    IF($A3="","",OFFSET(INDEX($F$3:$F$6,MATCH($A3,$F$3:$F$6,0)),,2+2*(IF($A2<>$A3,1,B2+1)-1),,))

    C3:
    =IF($A3="","",OFFSET(INDEX($F$3:$F$6,MATCH($A3,$F$3:$F$6,0)),,3+2*($D3-1),,))

    D3 (helper - which can be hidden, moved, or even be on another sheet):
    IF(A3="","",IF($A2<>$A3,1,D2+1))

    hi glenn.. thanks for the reply. i downloaded your file and pasted my data.. but the output table on the left is not exactly what im looking for. it seems only the first row is correct (green). the following data in red are wrong. the data in yellow did not appear on the output table.

    Capture.PNG

  7. #7
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,997

    Re: re-arranging data

    I cannot tell anything from a picture. Please attach the file.

    I have checked my file and it seems fine to me.

    Did you adjust the ranges to the formula to include all of the data?
    Attached Files Attached Files
    Last edited by Glenn Kennedy; 12-10-2019 at 03:57 AM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 8
    Last Post: 01-02-2019, 04:55 AM
  2. I need help re-arranging a data set
    By JarrettLogsdon in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-07-2017, 04:25 PM
  3. Re-arranging data
    By Macca_GB in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-02-2011, 07:08 PM
  4. Re-arranging the data
    By deepak.kec in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-21-2009, 02:00 AM
  5. data arranging
    By deepak.kec in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-21-2008, 05:08 AM
  6. arranging data using VBA
    By monty_mm in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-05-2008, 03:18 PM
  7. Arranging data
    By Petterq in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 10-12-2005, 03:05 PM

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