Bug 160155 - VLOOKUP-INDEX-MATCH: unexpected behaviour with alphanumeric values
Summary: VLOOKUP-INDEX-MATCH: unexpected behaviour with alphanumeric values
Status: CLOSED NOTABUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
24.2.0.3 release
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-03-11 16:03 UTC by bliss2u@gmx.net
Modified: 2024-03-11 16:30 UTC (History)
0 users

See Also:
Crash report or crash signature:


Attachments
VLOOKUP-INDEX-MATCH-Scenarios showing to discrepancy seen from standpoint of End User. (23.85 KB, application/vnd.oasis.opendocument.spreadsheet)
2024-03-11 16:03 UTC, bliss2u@gmx.net
Details

Note You need to log in before you can comment on or make changes to this bug.
Description bliss2u@gmx.net 2024-03-11 16:03:10 UTC
Created attachment 193065 [details]
VLOOKUP-INDEX-MATCH-Scenarios showing to discrepancy seen from standpoint of End User.

Hi and Good day everyone.

I expect a VLOOKUP is behaving the same way, no matter whether it's numeric or alphanumeric search-criterias (no matter whether it's the search value and or the searched value in the lookup table).

I understand what the MATCH-parameter 1 or 0 means.

I did create a couple scenarios showing these cases.

The same behaviour actually goes when using just LOOKUP or even the "handish" way with INDEX and MATCH.

When fields in question are alphanumeric, it's not behaving as expected. 
Sad.
I mean, a numeric content is a value, a alphanumeric content is a value too seen from the standpoint of a end user.
I know the technical background and difference of numeric and alphanumeric values. But an application like libreoffice is for end users, not only for computer nerds... ;-) 

See attached calc sheet demonstrating these cases

Thanks!

Lukas
Comment 1 ady 2024-03-11 16:19:02 UTC
Please specify exactly which cell(s) in attachment 193065 [details] other users should be looking at, together with:

* the Actual result you see, and
* the Expected result

...for such specific cell(s).
Comment 2 Eike Rathke 2024-03-11 16:24:12 UTC
You have regular expressions in formulas enabled, hence looking for value "[I5020]" searches a character of the set [I5020]. To search for the literal string either use "\[I5020\]" or force it to literal by surrounding it with \Q and \E, e.g.

=VLOOKUP("\Q"&C32&"\E";$B$3:$F$22;3;0)

See also https://help.libreoffice.org/7.6/en-GB/text/scalc/01/04060109.html?DbPAR=CALC#bm_id3153152

Not a bug.
Comment 3 bliss2u@gmx.net 2024-03-11 16:30:58 UTC
oops. Shame on me. 
To my defence: I receive that data and have to do with it something.
But totally missed the thing, that it's actually represeting a regular expression.

Therefore:

THANK YOU VERY MUCH!

One looks days and nights over this problem and cannot see the obvious!
Thanks
Best regards
Lukas