+ Reply to Thread
Results 1 to 23 of 23

Create multiple lists based on criteria from single column

  1. #1
    Registered User
    Join Date
    02-15-2023
    Location
    Utah, USA
    MS-Off Ver
    Microsoft 365
    Posts
    9

    Create multiple lists based on criteria from single column

    I have a file that I downloaded as a csv that I am not trying to organize for ease of use.*

    I want to create multiple column lists based on the criteria from another column.



    For example, I want to change this:

    Billing Admin View
    Billing Admin Edit
    Billing Admin Invoice
    Receptionist View
    Receptionist Edit
    Receptionist Schedule
    Receptionist Edit
    Receptionist Create

    To this:
    Billing Admin Receptionist
    View View
    Edit Edit
    invoice Add new
    schedule
    create


    I have tried the following:

    Transpose

    Pivot Table

    =IFERROR(INDEX(role_permission!B:B, MATCH(0, COUNTIF(A$1:A3, IF(role_permission!A:A=A$1,role_permission!B:B,A$1)), 0)),"")

    Filter formula



    None of these has been able to do the job at the scale that I need it done. I know I must be missing something.* I have attached the file for further reference. There are dozens of roles, I do not have time to copy and paste the list of roles over to a new sheet or workbook.*

  2. #2
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Cool Re: Create multiple lists based on criteria from single column

    with Power Query

    col1 col2 Billing Admin Receptionist
    Billing Admin View View View
    Billing Admin Edit Edit Edit
    Billing Admin Invoice Invoice Schedule
    Receptionist View Create
    Receptionist Edit
    Receptionist Schedule
    Receptionist Edit
    Receptionist Create


    Please Login or Register  to view this content.
    next time post excel file with representative example before and expected result

  3. #3
    Forum Expert
    Join Date
    02-10-2019
    Location
    Georgia, USA
    MS-Off Ver
    Office 365
    Posts
    2,829

    Re: Create multiple lists based on criteria from single column

    I'm guessing there's a better formula than this, but this gives your expected results:

    =LET(
    rnga,A1:A8,
    rngb,B1:B8,
    Header,TRANSPOSE(UNIQUE(rnga)),
    Data1,FILTER(rngb,rnga=INDEX(Header,,1)),
    Data2,FILTER(rngb,rnga=INDEX(Header,,2)),
    Data,IFERROR(HSTACK(Data1,Data2),""),
    VSTACK(Header,Data))

    Please Login or Register  to view this content.
    Attached Files Attached Files

  4. #4
    Registered User
    Join Date
    02-15-2023
    Location
    Utah, USA
    MS-Off Ver
    Microsoft 365
    Posts
    9

    Re: Create multiple lists based on criteria from single column

    Thank you! I will give it a try. Since it was my first post, it wouldn't let me attach anything...

  5. #5
    Registered User
    Join Date
    02-15-2023
    Location
    Utah, USA
    MS-Off Ver
    Microsoft 365
    Posts
    9

    Re: Create multiple lists based on criteria from single column

    I am not familiar with Power Query, can you elaborate or link me to a tutorial?

  6. #6
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Cool Re: Create multiple lists based on criteria from single column

    looks like you need to learn Power Query from scratch.
    I don't know of any tutorials other than that: Learn Power Query

    or use Google Search and YouTube Search

    or look at this file:
    Last edited by sandy666; 02-20-2023 at 11:18 AM. Reason: file added

  7. #7
    Registered User
    Join Date
    02-15-2023
    Location
    Utah, USA
    MS-Off Ver
    Microsoft 365
    Posts
    9

    Re: Create multiple lists based on criteria from single column

    Quote Originally Posted by Gregb11 View Post
    Data1,FILTER(rngb,rnga=INDEX(Header,,1)),
    Data2,FILTER(rngb,rnga=INDEX(Header,,2)),
    This is working perfectly! Is there a faster way to specify data sets? There are 465 unique sets.

  8. #8
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,178

    Re: Create multiple lists based on criteria from single column

    Please Login or Register  to view this content.
    Attached Files Attached Files
    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED.

  9. #9
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Create multiple lists based on criteria from single column

    @John

    it should be like this?

    Billing Admin View Billing Admin Receptionist Billing Admin
    Billing Admin Edit View View Edit
    Billing Admin Invoice Edit Edit View
    Receptionist View Invoice Schedule
    Receptionist Edit Edit
    Receptionist Schedule View
    Receptionist Edit Edit
    Receptionist View Edit
    Receptionist Edit Schedule
    Receptionist Edit
    Receptionist Schedule
    Billing Admin Edit
    Billing Admin View

  10. #10
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,178

    Re: Create multiple lists based on criteria from single column

    @Sandy666: not sure what you mean -see attached
    Attached Files Attached Files
    Last edited by JohnTopley; 02-21-2023 at 11:16 AM.

  11. #11
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,077

    Re: Create multiple lists based on criteria from single column

    Ignore.
    Think I realised what the OP was saying & provided a formula later in the thread
    Last edited by Fluff13; 02-20-2023 at 04:43 PM.

  12. #12
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Create multiple lists based on criteria from single column

    @John
    I think wrong file attached (post#10)

    Source Result Billing Admin Receptionist Billing Admin Receptionist
    Billing Admin View View View Edit Schedule
    Billing Admin Edit Edit Edit View Edit
    Billing Admin Invoice Invoice Schedule View
    Receptionist View Edit
    Receptionist Edit View
    Receptionist Schedule Edit
    Receptionist Edit Edit
    Receptionist View Schedule
    Receptionist Edit
    Receptionist Edit
    Receptionist Schedule
    Billing Admin Edit
    Billing Admin View
    Receptionist Schedule
    Receptionist Edit ___________________
    Receptionist View


    result with your vba
    Last edited by sandy666; 02-20-2023 at 01:22 PM.

  13. #13
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,178

    Re: Create multiple lists based on criteria from single column

    I added SORT to the macro so that all Roles are together although I assumed the default to be sorted list - why not ?! I'll await OP response.

  14. #14
    Banned User!
    Join Date
    02-05-2015
    Location
    San Escobar
    MS-Off Ver
    any on PC except 365
    Posts
    12,168

    Re: Create multiple lists based on criteria from single column

    IMHO it should be sorted (as you did in macro) and distinct (without repetition)
    but
    Quote Originally Posted by JohnTopley View Post
    I'll await OP response.

  15. #15
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,077

    Re: Create multiple lists based on criteria from single column

    Another formula
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  16. #16
    Registered User
    Join Date
    02-15-2023
    Location
    Utah, USA
    MS-Off Ver
    Microsoft 365
    Posts
    9

    Re: Create multiple lists based on criteria from single column

    I am going to input these now
    I am still trying to attach the file, it says I cannot until I post a few times...(it won't even let me tag anyone) Seems silly for a help forum, but okay.

  17. #17
    Registered User
    Join Date
    02-15-2023
    Location
    Utah, USA
    MS-Off Ver
    Microsoft 365
    Posts
    9

    Re: Create multiple lists based on criteria from single column

    Quote Originally Posted by Fluff13 View Post
    Ignore.
    Think I realised what the OP was saying & provided a formula later in the thread
    Sorry if I wasn't clear.
    My dataset is two columns labeled "role" and "permission"
    There are over 400 roles with corresponding positions. I need to take the "role" make it a header and have it fill in the corresponding "permissions" underneath.
    I know there are many ways to do this, I am just trying to find the simplest one. I do not know macros or pivot tables; my knowledge is very rudimentary.
    Formulas I understand for the most part. So io hope this is the one!

  18. #18
    Forum Expert
    Join Date
    02-10-2019
    Location
    Georgia, USA
    MS-Off Ver
    Office 365
    Posts
    2,829

    Re: Create multiple lists based on criteria from single column

    it says I cannot until I post a few times
    You should be able to. Read the instructions at the top (in yellow banner) closely. It's not intuitive unfortunately.

  19. #19
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,178

    Re: Create multiple lists based on criteria from single column

    Macro with SORT
    Attached Files Attached Files

  20. #20
    Registered User
    Join Date
    02-15-2023
    Location
    Utah, USA
    MS-Off Ver
    Microsoft 365
    Posts
    9

    Re: Create multiple lists based on criteria from single column

    Trying again
    Attached Files Attached Files

  21. #21
    Registered User
    Join Date
    02-15-2023
    Location
    Utah, USA
    MS-Off Ver
    Microsoft 365
    Posts
    9

    Re: Create multiple lists based on criteria from single column

    BEAUTIFUL! This worked immediately. Thank you so much!

  22. #22
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,077

    Re: Create multiple lists based on criteria from single column

    Glad to help & thanks for the feedback.

  23. #23
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,178

    Re: Create multiple lists based on criteria from single column

    Please Login or Register  to view this content.
    Attached Files Attached Files

+ 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. [SOLVED] XLOOKUP to return cell based on multiple criteria in single column
    By mikehay08 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 05-24-2021, 02:59 PM
  2. Replies: 2
    Last Post: 05-13-2020, 07:40 AM
  3. [SOLVED] Capturing Multiple Column’s Data in a Single Column Based on Criteria
    By Rajeshkumar R in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-22-2020, 01:40 PM
  4. Creating several lists based on single criteria
    By WebTrav in forum Excel General
    Replies: 1
    Last Post: 11-22-2019, 05:55 PM
  5. Extracting Unique List From Multiple Columns Based on Single-Column Criteria
    By Hellogiraffe in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-29-2019, 04:55 PM
  6. Replies: 1
    Last Post: 11-29-2017, 05:13 PM
  7. [SOLVED] How would one create a single list of #'s (array) from multiple lists (arrays)?
    By Rstrand in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 01-08-2013, 07:32 PM

Tags for this Thread

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