Bug 91751 - VLOOKUP ignores some characters
Summary: VLOOKUP ignores some characters
Status: RESOLVED NOTABUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
4.4.1.2 release
Hardware: Other All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-05-30 13:44 UTC by Tom B
Modified: 2015-05-30 14:24 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
Example of VLOOKUP bug (11.09 KB, application/vnd.oasis.opendocument.spreadsheet)
2015-05-30 13:44 UTC, Tom B
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Tom B 2015-05-30 13:44:45 UTC
Created attachment 116174 [details]
Example of VLOOKUP bug

When doing a VLOOKUP on a string in a list, some characters (e.g. + are ignored completely and instead strings that shouldn't match do.

In my example (attached), I have a set of grades with + and - so C+, C and C- with the relevant scores. Doing a VLOOKUP() with a value of C+ matches the C- row
Comment 1 m_a_riosv 2015-05-30 14:24:23 UTC
Hi @Tom_B, thanks for reporting.

I think what happen is that VLOOKUP() function uses regular expressions and '+' is part of them, there are two solutions.

1) Precede the '+' with the escape character '\' for regex -> '\+'
2) Disable regular expressions in:
    Menu/Tools/Options/LibreOffice calc/Calculate/Enable regular expression in formulas.

Change to notabug, please if you are not agree reopen it.