+ Reply to Thread
Results 1 to 11 of 11

Dependent lists based on multiple not unique table columns

  1. #1
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Dependent lists based on multiple not unique table columns

    Hi Guys,

    i have table like here:

    Screenshot_49.png

    and i wnat to do dependent unique lists (drop downs) from left to right in seperate table for user input.

    1. So in Division column i shouldhave just unique list based on division
    2. If user will choose "Xbox" he will have in Drop down in column App = "Baden" and "Marko" (no duplicates!) as result to choose
    3. If user will choose "Baden" - he will get only "4" in drop down in function column, if he will choose "Marko" he will get only "5" in function column in drop down lists.

    Can anybody help how to build ?
    Maybe pivot table?

    Hmm please help,
    Jacek
    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,926

    Re: Dependent lists based on multiple not unique table columns

    This has been asked and covered many, many times on the forums. We usually offer links to the many online tutorials. Here's one good one: https://www.contextures.com/xlDataVal02.html
    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
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Re: Dependent lists based on multiple not unique table columns

    hi, i looked up on the forum and didnt find.
    thank you for getting involved.

    Also,

    i know the website provided. And i looked also for other solutions. There is no what i am looking for - exactly in details i described what the goal is and attached example.
    There is a way to have seperate lists which are refering one to other. But there we do not have duplicates. And there are in seperated lists not i one table with specific column names.

    My case is different.
    I want first of all get rid of duplicates from table in drop downs.
    Second i want to restrict each column from left to right and have only uniques in my drop downs.

    As in example for "Xbox".

    Please help,
    Jacek

  4. #4
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,466

    Re: Dependent lists based on multiple not unique table columns

    Try to create helper table to list unique Division, App and Function, then using them for Data Validation
    See attachment.
    Attached Files Attached Files
    Quang PT

  5. #5
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Re: Dependent lists based on multiple not unique table columns

    o wow thank you very muhc bebo021999!!!

    God bless you!
    Jacek

  6. #6
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Re: Dependent lists based on multiple not unique table columns

    Ok i will reopen topic because when i have 10 columns this solution seems to be very hard to implement

    For each column i have to create sepearate list plus add multiple formulas.

    Maybe somebody knows any different ideas?

    Jacek

  7. #7
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Re: Dependent lists based on multiple not unique table columns

    Hi,

    anyone has another idea or it is rather not possible?

    Jacek

  8. #8
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Re: Dependent lists based on multiple not unique table columns

    Ah i have noticed just now one more thing,

    if i have data like here:

    Screenshot_51.png

    So "Baden" can be characteristic for "Game" and "Xbox" then provided solution is not working.
    I have no idea how can i check this.

    bebo021999 can you please check this?
    Or somebody else?

    Screenshot_52.png

    as you can see count ifs is taking the first 2 rows because Baden is also in first row...so i am getting 8 and 8 instead 4 and 5 characteristic for Baden and Xbox together.

    Thank you !!
    Jacek
    Attached Files Attached Files
    Last edited by jaryszek; 07-30-2020 at 04:20 AM.

  9. #9
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Re: Dependent lists based on multiple not unique table columns

    Ok Guys!

    i did the workaround for it but hope that someone smarter than me will figure out something easier to implmenent.

    I added pivot tables as many as column number for drop downs - so in this case 3.

    And with VBA i am creating key for each pivot which is concatenation of each row from pt.
    And next i am using formulas something similar like here:

    Please Login or Register  to view this content.
    So pivot table ensures that i do not have any duplicates plus key ensures that i can have different configurations for lookup string.
    Solution is fast because VBA is run only one time to get keys and based on those keys i have named ranges which i can use in drop downs.

    Anyone has easier solution?

    Best,
    Jacek

  10. #10
    Valued Forum Contributor
    Join Date
    02-02-2016
    Location
    Indonesia
    MS-Off Ver
    Office 365
    Posts
    1,004

    Re: Dependent lists based on multiple not unique table columns

    Hi, jaryszek

    This thread is several months old but you asked for a different solution, so:
    Here's an example of multiple dependent data validation using VBA.
    This method will make it easier to maintain the data set because you only need 1 table.

    Note:
    1. You can set up 2 or 3 or more dependent data validation.
    Change this part to suit:
    '=============== YOU MAY NEED TO ADJUST THE CODE IN THIS PART:

    2. One caveat of using macro is when a macro changes/writes something in the sheet it will clear the Undo Stack, so at that point you can't use UNDO.
    In this case it happens whenever you put the cursor in the cell with the data validation.


    The example:

  11. #11
    Forum Contributor
    Join Date
    01-16-2014
    Location
    Poland
    MS-Off Ver
    Excel 2016-365
    Posts
    2,940

    Re: Dependent lists based on multiple not unique table columns

    Thank you!

    I will take a look,

    Jacek

+ 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: 0
    Last Post: 07-01-2015, 09:49 AM
  2. Multiple Dependent Lists based on Selection in 1st Column
    By TinkerBleu in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 05-02-2015, 07:05 AM
  3. Dependent drop down lists without creating unique named lists
    By pajordan in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-11-2013, 12:20 PM
  4. Validation Lists - Multiple dependent lists with unique values
    By Lewigi in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-16-2013, 06:42 AM
  5. Multiple Rows and Columns in Dependent Dropdown Lists
    By JS1990 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 06-27-2013, 08:23 PM
  6. [SOLVED] Multiple dependent lists with unique results
    By Jeepster325 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 03-05-2013, 01:14 PM
  7. multiple validation dependent lists based one one source but not on each other?
    By erinkm in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-13-2012, 03:15 AM

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