+ Reply to Thread
Results 1 to 12 of 12

problem using wildcards in INDEX / MATCH formula

  1. #1
    Registered User
    Join Date
    02-19-2019
    Location
    NYC
    MS-Off Ver
    Office Home and Student 2016
    Posts
    4

    problem using wildcards in INDEX / MATCH formula

    I am trying to work out a spreadsheet to fill in my monthly charges from my bank statement.

    I have columns for months and rows for different charges.

    My data has columns for months, charges and amounts.

    I want to fill the amount into my spreadsheet.

    The challenge I have is that the charge descriptor in the data has a lot of extraneous bank gibberish. I want to search the cell for the keyword I need (for example, "Discover" for my Discover card bill.

    Here is the formula I have that works if I strip out the charge fields to just the keyword I want.

    =INDEX($E$2:$E$334,MATCH(1,('2018 Table'!B$1=$A$2:$A$334) * ('2018 Table'!$A$2=$D$2:$D$334),0))

    Column E is the amounts, column A is the month and column D is the charge description.

    I modified the formula like this to try and get the wildcards to work -

    =INDEX($E$2:$E$334,MATCH(1,('2018 Table'!B$1=$A$2:$A$334) * ("*Discover*"=$D$2:$D$334),0))

    but it didn't work.

    I tried this

    =INDEX($E$2:$E$334,MATCH(1,('2018 Table'!B$1=$A$2:$A$334) * ('2018 Table'!$A$2&"*"=$D$2:$D$334),0))

    and it also didn't work.

    I also tried "*"&'2018 Table'!$A$2&"*"
    with no luck.

    Could the problem be that I am trying to compare two arrays and that wildcards don't work when using MATCH with two criteria?

    Or am I missing something?

    Thanks for any help you can provide.
    Last edited by edteitz; 02-19-2019 at 11:56 PM. Reason: clarification

  2. #2
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: problem using wildcards in INDEX / MATCH formula

    Attach a sample workbook (not a picture or pasted copy). Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.
    If posting code please use code tags, see here.

  3. #3
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: problem using wildcards in INDEX / MATCH formula

    Hello edteitz. Welcome to the forum.

    Have a look at the MATCH function help file.

    MATCH(lookup_value, lookup_array, [match_type])

    Wild cards only apply to the lookup_value.

    If the lookup_value you are using also contains some of the "gibberish" ... eg "****" ... you will need to take extra steps

    ##If match_type is 0 and lookup_value is a text string, you can use the wildcard characters — the question mark (?) and asterisk (*) — in the lookup_value argument. A question mark matches any single character; an asterisk matches any sequence of characters. If you want to find an actual question mark or asterisk, type a tilde (~) before the character.[emphasis added]
    Does any of this help?
    Dave

  4. #4
    Valued Forum Contributor
    Join Date
    04-27-2015
    Location
    Abu Dhabi, U.A.E
    MS-Off Ver
    Office 365 | 2016
    Posts
    696

    Re: problem using wildcards in INDEX / MATCH formula

    Are you looking for this?
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    02-19-2019
    Location
    NYC
    MS-Off Ver
    Office Home and Student 2016
    Posts
    4

    Re: problem using wildcards in INDEX / MATCH formula

    Dave,

    Thanks for the welcome. And the information.

    Yes, I am aware that wildcards only work for the lookup value.

    My issue does not come up when I use MATCH this way:
    MATCH(lookup_value, lookup_array, [match_type])

    It only comes up when I use it with two criteria like this:
    MATCH(1, (lookup_value=lookup_array) * (lookup_value=lookup_array), [match_type]).

    Any ideas?

  6. #6
    Forum Expert rorya's Avatar
    Join Date
    08-13-2008
    Location
    East Sussex, UK
    MS-Off Ver
    365 Ent Monthly Channel / Insiders Beta
    Posts
    8,907

    Re: problem using wildcards in INDEX / MATCH formula

    Try this:

    =INDEX($E$2:$E$334,MATCH(1,('2018 Table'!B$1=$A$2:$A$334) * (ISNUMBER(SEARCH('2018 Table'!$A$2,$D$2:$D$334))),0))
    Rory

  7. #7
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: problem using wildcards in INDEX / MATCH formula

    Withdrawn.

    Rory beat me to it.

  8. #8
    Registered User
    Join Date
    02-19-2019
    Location
    NYC
    MS-Off Ver
    Office Home and Student 2016
    Posts
    4

    Re: problem using wildcards in INDEX / MATCH formula

    Rory(and Flame Retired),

    Thanks. Works like a charm.

    Shareez,

    You went above and beyond! I didn't need the functionality of summing different lines. But I'm going to use your code in other applications. Very much appreciated.


    EDT

  9. #9
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: problem using wildcards in INDEX / MATCH formula

    You are welcome. Glad to help ... (or sort of help LOL )

    Thank you for the feedback and marking your thread Solved.

  10. #10
    Registered User
    Join Date
    02-19-2019
    Location
    NYC
    MS-Off Ver
    Office Home and Student 2016
    Posts
    4

    Re: problem using wildcards in INDEX / MATCH formula

    The problem wasn't technically solved. It was worked around.

    I'm still interested in knowing if my problem is a known bug.


    E

  11. #11
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: problem using wildcards in INDEX / MATCH formula

    Couldn't say without a representative workbook upload that includes the malfunctioning formulas.

    If you are not familiar with how to do that:

    To attach a file to your post: (Please no pics or screenshots ... saves retyping data.),

    be sure to desensitize the data
    • click “Go Advanced” (next to Post Quick Reply – bottom right),
    • scroll down until you see “Manage Attachments”, click that,
    • click “Browse”.
    • select your file(s)
    • click “Upload”
    • click “Close window”
    • click “Submit Reply”
    The file name will appear at the bottom of your reply.

  12. #12
    Forum Expert rorya's Avatar
    Join Date
    08-13-2008
    Location
    East Sussex, UK
    MS-Off Ver
    365 Ent Monthly Channel / Insiders Beta
    Posts
    8,907

    Re: problem using wildcards in INDEX / MATCH formula

    It's not a bug. Wildcards don't work with =, that's just the way it is.

+ 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] Possible sum/match/index formula problem
    By skyep2058 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 02-02-2019, 02:10 PM
  2. Using wildcards to get an exact match using vlookup or index and match
    By Martynw2005 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 06-15-2015, 09:56 PM
  3. [SOLVED] Index and Match with Wildcards
    By pytheus in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 06-23-2014, 08:43 PM
  4. [SOLVED] Make an Index/Match Sum Array with wildcards
    By TheAlchemyst in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 04-28-2014, 06:48 PM
  5. Problem with Index and Match formula
    By annupojupradeep in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 04-03-2013, 08:01 PM
  6. [SOLVED] Problem with my INDEX and MATCH formula
    By eoghanmolloy in forum Excel Formulas & Functions
    Replies: 15
    Last Post: 11-19-2012, 01:10 PM
  7. Problem with Index and Match Formula
    By rbpd5015 in forum Excel General
    Replies: 1
    Last Post: 12-01-2011, 10:38 AM

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