#### gorem

##### Board Regular
I'm not sure if it's heresy to ask about Google Sheets here, but I have a wildcard lookup question and figured you all are the most reliable source. I'm helping out a friend whose organization uses Google Sheets (the reason I can't just solve this in Excel).

In this scenario, dates on a calendar are the lookup values (e.g. 9/1/2014). On another sheet, I want to either return a value corresponding to either "9/1/2014" or "9/1/2014 pm" in an adjacent cell (only one or the other will ever be represented). One other variable to consider is that there are sometimes trailing spaces or different numbers of spaces between the date and the "pm". In Excel, I would do something like =INDEX(Sheet2!C:C,MATCH(A2&"*pm*",Sheet2!A:A,0)).

However, I've read that Google Sheets doesn't support wildcards in the same way as Excel. People recommend some combination of FILTER and SEARCH, which are totally foreign to me. I used to following workaround, but wondering if others have more flexible solutions that will take variations of the lookup value into account:

=IFERROR(IFERROR(INDEX(Sheet2!\$E:\$E,MATCH(E3&" pm",Sheet2!\$B:\$B,0)),INDEX(Sheet2!\$E:\$E,MATCH(E3,Sheet2!\$B:\$B,0))),"")

### Excel Facts

Can you AutoAverage in Excel?
There is a drop-down next to the AutoSum symbol. Open the drop-down to choose AVERAGE, COUNT, MAX, or MIN
Is there a need to repeat the INDEX?

=IFERROR(INDEX(Sheet2!\$E:\$E,IFERROR(MATCH(E3&" pm",Sheet2!\$B:\$B,0),MATCH(E3,Sheet2!\$B:\$B,0))),"")

Excellent point! No, yours is more efficient.

I still would love to know how to deal with variations in my lookup array, however. The formula above doesn't take some fuzzy matches into account given the wildcard limitations in Google Sheets

Thanks!

Replies
2
Views
195
Replies
3
Views
274
Replies
4
Views
62
Replies
19
Views
860
Replies
2
Views
83

1,214,323
Messages
6,118,890
Members
448,854
Latest member
Eduard_Stoo

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.

### Which adblocker are you using?

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back