+ Reply to Thread
Results 1 to 5 of 5

Searching multiple values in a data set

Hybrid View

  1. #1
    Registered User
    Join Date
    01-03-2012
    Location
    Holland, MI, USA
    MS-Off Ver
    Excel 2007
    Posts
    7

    Searching multiple values in a data set

    So I have a little bit of a problem and I'm not quite sure how to go about it. I have a large list of data. Each of these data items has a list attached to it, detailing some information about that particular piece of data.

    What I would like to do is have some sort of list box (or a series of check boxes perhaps?) that would list all of the possible detail options (which are a set number) that the user can select and then would return all of the data that match this criteria.

    For example:
    data details
    data 1 1 2 3 4 5
    data 2 1 3 5 7 9
    data 3 1 2 3 5 7
    data 4 2 4 6 8 10

    Now the user would select say "1" "2" and "5" The program would return data 1 and data 3.

    Any suggestions?

  2. #2
    Forum Expert dilipandey's Avatar
    Join Date
    12-05-2011
    Location
    Dubai, UAE
    MS-Off Ver
    1997 - 2016
    Posts
    8,191

    Re: Searching multiple values in a data set

    Hi Davi,

    As an option DGET function can be used, see the attachment.


    Regards,
    DILIPandey

    <click on below 'star' if this helps>
    Attached Files Attached Files
    DILIPandey, Excel rMVP
    +919810929744 (India), +971528225509 (Dubai), [email protected]

  3. #3
    Registered User
    Join Date
    01-03-2012
    Location
    Holland, MI, USA
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Searching multiple values in a data set

    Quote Originally Posted by dilipandey View Post
    Hi Davi,

    As an option DGET function can be used, see the attachment.


    Regards,
    DILIPandey

    <click on below 'star' if this helps>
    Thank you for the response, but I don't think that this solves my problem. There are two issues with it that I can see based on my situation. One it that it has problems (or I have problems I suppose haha) with it returning multiple values if multiple "data" match the conditions specified. Two is that it requires the data to be in very specific order to match. For example, in your spreadsheet, if I put the numbers 1,2,3 in cells H2:J2, I receive a #NUM! error from the DGET command. If I enter 2,3,4 in the same cells, I get a #VALUE! error even though "data 1" contains these value.

    Perhaps a better example is in order:

    Movie Genre
    Titanic Action Drama History
    Casablanca Drama Romance War
    Citizen Kane Drama Mystery
    Pulp Fiction Crime Thriller
    The Godfather Crime Drama


    This could be considered part of the list, that is to say, there are many more options for the genre category as well as many more films on the list. Now the user would be able to select one of the genres (Drama) and it would return all of the movies that are part of that genre (Titanic, Casablanca, Citizen Kane, and The Godfather). As you can see from the list, the same genre will not always be in the same column, nor will the results be limited to one movie.

    I suppose I could use the DGET command on each line to eliminate the multiple result problem, but that seems awfully clumsy and does not fix the other issue

  4. #4
    Forum Expert dilipandey's Avatar
    Join Date
    12-05-2011
    Location
    Dubai, UAE
    MS-Off Ver
    1997 - 2016
    Posts
    8,191

    Re: Searching multiple values in a data set

    Hi Davi,

    Thanks for encouraging words

    See the attachment where I have given an option to you.

    Regards,
    DILIPandey

    <click on below 'star' if this helps>
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    01-03-2012
    Location
    Holland, MI, USA
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Searching multiple values in a data set

    still not quite what I'm looking for, but it should get me going in the right direction. Thanks for the help

+ 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