+ Reply to Thread
Results 1 to 37 of 37

vlookup with wildcard not working

  1. #1
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    vlookup with wildcard not working

    Hi,

    Can anyone help please...…


    I am trying to use vlookup with wildcard but it doesn't seem to work.
    Attached Files Attached Files

  2. #2
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    Northumberland, UK
    MS-Off Ver
    various
    Posts
    2,704

    Re: vlookup with wildcard not working

    If I've understood:

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

  3. #3
    Forum Expert BMV's Avatar
    Join Date
    01-13-2020
    Location
    St-Petersburg, Russia
    MS-Off Ver
    2013-2016
    Posts
    1,329

    Re: vlookup with wildcard not working

    Please Login or Register  to view this content.

  4. #4
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    thank you very much this has been bugging me for ages. if you don't mind helping me another issue. I have attached the excel sheet. your help is much appreciated
    Attached Files Attached Files

  5. #5
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    Northumberland, UK
    MS-Off Ver
    various
    Posts
    2,704

    Re: vlookup with wildcard not working

    not sure I fully understand the requirement but, perhaps:

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    note: I opt to apply a space delimiter to both description (source) and search terms, in these scenarios, to mitigate risk of false positives - e.g. "car" + "carpet"
    Last edited by XLent; 05-06-2020 at 03:05 AM. Reason: added note (re: rational for different approach to BMV)

  6. #6
    Forum Expert avk's Avatar
    Join Date
    07-12-2007
    Location
    India
    MS-Off Ver
    Microsoft Office 2013
    Posts
    3,223

    Re: vlookup with wildcard not working

    may be "D6"
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    "E6"
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    copy paste down


    atul


    If my answer (or that of other members) has helped you, please say "Thanks" by clicking the Add Reputation button at the foot of one of their posts.

    Also: if your problem is solved, please take the time to mark your thread as SOLVED by going to the top of your first post, selecting "Thread Tools" and then "Mark thread as solved".

  7. #7
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    worked perfectly thank you so much

  8. #8
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    Quote Originally Posted by XLent View Post
    not sure I fully understand the requirement but, perhaps:

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    note: I opt to apply a space delimiter to both description (source) and search terms, in these scenarios, to mitigate risk of false positives - e.g. "car" + "carpet"
    worked perfectly

  9. #9
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    Quote Originally Posted by XLent View Post
    If I've understood:

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Quote Originally Posted by XLent View Post
    not sure I fully understand the requirement but, perhaps:

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    note: I opt to apply a space delimiter to both description (source) and search terms, in these scenarios, to mitigate risk of false positives - e.g. "car" + "carpet"
    I found a slight issue, when searching a word and its without a space then it does not locate, e.g. Screwfix.com then it does not find a respond
    Attached Files Attached Files
    Last edited by DEEARO; 05-09-2020 at 10:04 AM.

  10. #10
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    Northumberland, UK
    MS-Off Ver
    various
    Posts
    2,704

    Re: vlookup with wildcard not working

    please don't quote entire posts... just quote relevant parts (if necessary).

    For your specific request, either

    a) replace the non-space word delimiters with a space, e.g.

    =IF(COUNT(C12),LOOKUP(9.99E+307,SEARCH(" "&TRIM(DEE[KEY])&" "," "&SUBSTITUTE($A12,"."," ")&" "),DEE[[DESCRIPTION ]]),"")
    confirmed with Enter (not Array)

    or

    b) accept risk of false positives and revert to an approach without delimiter (provided earlier by another)

    =LOOKUP(9.99E+307,SEARCH($I$6:$I$11,$A12),$J$6:$J$11)
    confirmed with Enter

    the risk of b is simply if your criteria values (Col I) are not mutually exclusive... e.g.

    Col I contains both "carrot" and "car", with "food" and "repairs" as respective categories...

    If your source data read "carrot cake" you would always get "repairs" returned as this would be the last valid match in your search terms (car)

    so, if using b, just be careful how you sort your values in Col I.

  11. #11
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    For your specific request, either

    a) replace the non-space word delimiters with a space, e.g.

    =IF(COUNT(C12),LOOKUP(9.99E+307,SEARCH(" "&TRIM(DEE[KEY])&" "," "&SUBSTITUTE($A12,"."," ")&" "),DEE[[DESCRIPTION ]]),"")
    confirmed with Enter (not Array)

    this works in most places but I still have few area in my data sheet


    for example CARD PAYMENT TO ISLEWORTH,1.60 GBP, RATE 1.00/GBP ON 10-12-2019, shows N/A as I am looking up Isleworth
    Attached Files Attached Files

  12. #12
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    Northumberland, UK
    MS-Off Ver
    various
    Posts
    2,704

    Re: vlookup with wildcard not working

    Two things

    1. as mentioned earlier - you need to replace any word separator that is not a space with space (to use option a)

    so you need to SUBSTITUTE both the full stop, and the comma, e.g.

    =IF(COUNT(C13),LOOKUP(9.99E+307,SEARCH(" "&TRIM(DEE[KEY])&" "," "&SUBSTITUTE(SUBSTITUTE($A13,"."," "),","," ")&" "),DEE[[DESCRIPTION ]]),"")
    the more delimiters you have the more complex this can become, obviously

    2. in your sample the spelling of Isleworth is incorrect in Col I

  13. #13
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    I AM REALLY SORRY FOR ALL THE QUESTIONS.

    All your formulas work in my actual table that I am using after editing table name and row/Coolum, however when I am typing the new formula into excel I get an error and excel auto changing it (see below) and I believe this preventing it from working in my table, any ideas please.

    =IF(COUNT(D2),LOOKUP(9E+99+307,SEARCH(" "&TRIM(SOUT1[KEY])&" "," "&SUBSTITUTE(SUBSTITUTE($B2,"."," "),","," ")&" "),SOUT1[DESCRIPTION]),"")

  14. #14
    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,980

    Re: vlookup with wildcard not working

    Try this:

    =IF(COUNT(D2),LOOKUP(9999999999999999,SEARCH(" "&TRIM(SOUT1[KEY])&" "," "&SUBSTITUTE(SUBSTITUTE($B2,"."," "),","," ")&" "),SOUT1[DESCRIPTION]),"")
    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.

  15. #15
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    =IF(COUNT(D2),LOOKUP(9.99E+307,SEARCH(" "&TRIM(DEE[KEY])&" "," "&SUBSTITUTE(SUBSTITUTE($B2,"."," "),","," ")&" "),SOUT1[[DESCRIPTION ]]),"")
    =IF(COUNT(D2),LOOKUP(9999999999999999,SEARCH(" "&TRIM(DEE[KEY])&" "," "&SUBSTITUTE(SUBSTITUTE($B2,"."," "),","," ")&" "),SOUT1[DESCRIPTION]),"")

    Both these formulas are giving me errors, even when the previous formula was finding results. The previous formula works better but does work in every scenarios e.g CARD PAYMENT TO ISLEWORTH,1.60 GBP, RATE 1.00/GBP ON 10-12-2019

    =IF(COUNT(C12),LOOKUP(9.99E+307,SEARCH(" "&TRIM(DEE[KEY])&" "," "&SUBSTITUTE($A12,"."," ")&" "),DEE[[DESCRIPTION ]]),"")

  16. #16
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    Northumberland, UK
    MS-Off Ver
    various
    Posts
    2,704

    Re: vlookup with wildcard not working

    given the mixed references in the formulas above, both range & table, it's hard to offer any guidance.

    Referring back to post#12, the formula provided worked for the sample file provided, once the misspelling of Isleworth was corrected in the reference table.

    If what you have is not working this implies that either

    a) you have copied the formula incorrectly and/or are applying the wrong cell references,
    b) you have not corrected misspellings, or
    c) you have other delimiters to account for that you've yet to illustrate.

  17. #17
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    Hi have uploaded a sample of the excel sheet I been using. The Formula is not working (sheet 1). The Ref Sheet is the where the 2 tables are for the key and description are.
    Attached Files Attached Files

  18. #18
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    Northumberland, UK
    MS-Off Ver
    various
    Posts
    2,704

    Re: vlookup with wildcard not working

    your issue is that you now have blank search terms, a new development / requirement - change in red below.

    =IF(COUNT(C2),LOOKUP(9.99E+307,SEARCH(" "&TRIM(DEE[KEY])&" "," "&SUBSTITUTE(SUBSTITUTE($B2,"."," "),","," ")&" ")/(DEE[KEY]<>""),DEE[DESCRIPTION]),"")
    confirmed with Enter

    you will still need to wrap the above in an IFERROR handler to handle things with no match - i.e.

    =IFERROR(IF(COUNT....),""),"")

  19. #19
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    please show me in the excel sheet as not sure how to implement the formula
    Attached Files Attached Files

  20. #20
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    I have uploaded a spreadsheet with both the new and previous formula. the new formula doesn't seem t be working on my spreadsheet.
    Attached Files Attached Files

  21. #21
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    Northumberland, UK
    MS-Off Ver
    various
    Posts
    2,704

    Re: vlookup with wildcard not working

    you are not using the formula provided for your prior requirement, which is not an array formula.

    there's nothing further I can add to this thread.

    please close, and start a new thread as your requirements have changed, yet again.

    edit:
    per below, Mod has stated you may continue to deviate the thread from original requirement
    Last edited by XLent; 05-13-2020 at 05:24 AM.

  22. #22
    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,980

    Re: vlookup with wildcard not working

    No - please do NOT start a new thread. The issue should remain here, even if the requirements have changed.

    Thanks.

  23. #23
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    hi Xlent I have not changed the requirements, it is the same. I am only using the formula mentioned on this forum. Column G is your previous formula which is working
    IF(COUNT(D3),LOOKUP(9E+99+307,SEARCH(" "&TRIM(SOUT1[KEY])&" "," "&$B3&" "),SOUT1[DESCRIPTION]),"")

    and column F is not working
    =IF(COUNT(D3),LOOKUP(9999999999999990,SEARCH(" "&TRIM(SOUT1[KEY])&" "," "&SUBSTITUTE(SUBSTITUTE($B3,"."," "),","," ")&" "),SOUT1[DESCRIPTION]),"")
    Last edited by DEEARO; 05-13-2020 at 12:54 PM.

  24. #24
    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,980

    Re: vlookup with wildcard not working

    Did you see the message to you in one of your other threads?

    You need to stop opening threads on issues that you claim are different, but are in fact all ostensibly the same.

    Please nominate ONE of your threads to keep open, and I will close the rest. Do you want this one to stay open?

  25. #25
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    Hi Ali we have already discussed this. I already mentioned i have three threads open and they all different, and you said that's fine. Don't understand why this issue has been brought up again

  26. #26
    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,980

    Re: vlookup with wildcard not working

    If you look at the time stamp of the post, you'll see that it was made before our 'discussion'.

    I am not alone in feeling that you are opening too many threads on interconnected issues, thus creating a certain amount of confusion, so please don't open any more until the current ones are resolved. After that, you really are much better off dealing with one issue at a time.

  27. #27
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282
    Hi Ali, going forward i will create 1 thread at a Tim be.

  28. #28
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    Hi all

    Please look at post 20, anyone able to solve please?

  29. #29
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    Hi all

    Please look at post 20, anyone able to solve please?

  30. #30
    Forum Expert BMV's Avatar
    Join Date
    01-13-2020
    Location
    St-Petersburg, Russia
    MS-Off Ver
    2013-2016
    Posts
    1,329

    Re: vlookup with wildcard not working

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

  31. #31
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    Thank you BMV for helping me out. The solution has solved some areas, but sometimes the old formula finds results but your new formula does not. Please see attach excel sheet.
    Attached Files Attached Files

  32. #32
    Forum Expert BMV's Avatar
    Join Date
    01-13-2020
    Location
    St-Petersburg, Russia
    MS-Off Ver
    2013-2016
    Posts
    1,329

    Re: vlookup with wildcard not working

    I don't know the reason to clear text from dot and comma but it must be done for both part
    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by BMV; 06-15-2020 at 01:19 PM.

  33. #33
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    Hi BMV

    i have tried your new formula I am getting errors. Please see attached spreadsheet. If you get the formula to work, please upload an excel with it working, makes it easier
    Attached Files Attached Files

  34. #34
    Forum Expert BMV's Avatar
    Join Date
    01-13-2020
    Location
    St-Petersburg, Russia
    MS-Off Ver
    2013-2016
    Posts
    1,329

    Re: vlookup with wildcard not working

    look at the #32

  35. #35
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    hi BMV the file doesnt seem to be working for me, please kindly can you reupload it with your new forumala

  36. #36
    Forum Expert BMV's Avatar
    Join Date
    01-13-2020
    Location
    St-Petersburg, Russia
    MS-Off Ver
    2013-2016
    Posts
    1,329

    Re: vlookup with wildcard not working

    Did you try attached file?

  37. #37
    Forum Contributor
    Join Date
    05-03-2020
    Location
    London
    MS-Off Ver
    MICROSOFT 365
    Posts
    282

    Re: vlookup with wildcard not working

    Hi BMV, thank you very much. I got it to work. The problem has now been solved.

    Everyone thank you soooooooooooooooooooooooooooooooooo much for all the help and quick responses.

+ 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] IF statement with a Wildcard not working, workaround?
    By Funkymonkey0073 in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 04-02-2019, 09:26 AM
  2. VLOOKUP - Wildcard not working
    By jerryr0125 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-29-2018, 07:20 PM
  3. MS Query wildcard with parameter NOT working, help please
    By BeauTiesLTD in forum Excel General
    Replies: 1
    Last Post: 06-14-2016, 11:57 AM
  4. Lookup not working with wildcard?
    By mikey42979 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-19-2016, 12:37 PM
  5. [SOLVED] Wildcard not working in my COUNTIFS
    By dtrimble in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 12-11-2013, 09:12 PM
  6. LIKE not working with wildcard in MS Query
    By RollerRagerMD in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-03-2013, 10:02 AM
  7. [SOLVED] Wildcard Not Working in IF statement
    By [email protected] in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 01-09-2005, 04:08 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