VLOOKUP Not Working With Primary Column Indented Values
I have a nested IF statement with a VLOOKUP that seems to have stopped working. For debugging, I've stripped out all but the VLOOKUP function and made the search value static, "DSHS".
Formula: =VLOOKUP("DSHS", [Agency & Administration]23:[Agency-Div Sort Order]24, 22, false)
"Agency & Administration" is the Primary Column and column 1 in the lookup table.
"Agency-Admin Sort Order" is column 22 in the lookup table. (23 total columns in the table.)
With the lookup table restricted to a single row, 23, the formula works with a result of "10000". When I expand the lookup table to include row 24, it returns "#INVALID OPERATION".
When I change the search value to "ALTSA" and the lookup table rows to 25-33 it correctly returns "11100". When I expand the lookup table by 1 row to 25-34, it's "#INVALID OPERATION".
Answers
-
What exactly are you wanting to accomplish?
-
I'll lead with, I'm not looking for a different way to do it. I can think of at least one other method that might work. I posted because it appears there's a bug in VLOOKUP right now, as described in the post. I did find in this community forum that someone else had this problem in ~2021-2022.
But the specific answer is… This sheet supports multiple reports. One report uses summary data in the 'top half' of the sheet. Another report uses data in the 'bottom half' of the report. The "Agency & Administration" column values are repeated, but not necessarily 1:1 between 'top half' and 'bottom half'. Rows 23 thru 114 have sort orders assigned to them in columns 22 & 23. Beginning in row 116, I want to populate the already-assigned (from the 'top half') sort orders when the "Agency & Administration" values match.
As mentioned in the OP, it works when there's no indentation of the values in the "Agency & Administration" column. It sometimes works when there are only two levels of indentation but not always, as described in the OP if you follow along with my narrative.
-
If it is a bug and you are not looking for another way to accomplish this, then you may want to reach out to support instead.
.
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.7K Get Help
- 433 Global Discussions
- 136 Industry Talk
- 468 Announcements
- 4.9K Ideas & Feature Requests
- 143 Brandfolder
- 147 Just for fun
- 64 Community Job Board
- 466 Show & Tell
- 32 Member Spotlight
- 2 SmartStories
- 298 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!