Bug 45134

Summary: Error in the INDIRECT function
Product: LibreOffice Reporter: Michel P <mhp.artetphoto>
Component: CalcAssignee: Not Assigned <libreoffice-bugs>
Status: VERIFIED FIXED    
Severity: normal CC: gerard.fargeot
Priority: medium    
Version: 3.4.5 release   
Hardware: All   
OS: All   
Whiteboard:
Crash report or crash signature: Regression By:
Attachments: Fragment of original file creating error

Description Michel P 2012-01-23 09:33:01 UTC
Created attachment 56046 [details]
Fragment of original file creating error

On "Facturation" tab, line 17, Indirect function calling a named range generates an error 502 since moving to LibreOffice. The spreadsheet opens correctly in OpenOffice 3.3 and in Excel when saved as ".xls".
Formula in error
=IF(ISNUMBER($A17);VLOOKUP($A17;INDIRECT($K17);B$15;FALSE());"")
Result
Err :502
where $K17 is the name of the range
If INDIRECT is replaced by its result (here "FRANCE")
=IF(ISNUMBER($A17);VLOOKUP($A17;France;B$15;FALSE());"")
the formula computes properly.
Comment 1 GerardF 2012-01-23 09:49:20 UTC
(In reply to comment #0)

> If INDIRECT is replaced by its result (here "FRANCE")
> =IF(ISNUMBER($A17);VLOOKUP($A17;France;B$15;FALSE());"")
> the formula computes properly.

When i hit Ctrl+F3, i saw the name "France".
In K17 you write "FRANCE".

If i change "FRANCE" for "France" in K17 (same case as defined name) it works.
Comment 2 Markus Mohrhard 2012-01-27 04:43:17 UTC
Can you check in 3.5? I removed the case sensitive handling of range names there and we are going to backport this change to 3.4.6 if it does not show any problems.
Comment 3 Michel P 2012-01-29 02:04:06 UTC
(In reply to comment #2)
> Can you check in 3.5? I removed the case sensitive handling of range names
> there and we are going to backport this change to 3.4.6 if it does not show any
> problems.

3.5 solves the problem. Great. Thank you. Good work.
Comment 4 Michael Duelli 2013-06-23 14:03:08 UTC
Just checked with git master (Version: 4.2.0.0.alpha0+ Build ID: 3dac2c4b5d6aab37181cf6b113ec1a6732c2d2da).

Confirm this is working and is case-insensitive.