Bug 50345 - EDITING: Parsing value of cell with empty string gives #VALUE!
Summary: EDITING: Parsing value of cell with empty string gives #VALUE!
Status: RESOLVED DUPLICATE of bug 44720
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
3.5.3 release
Hardware: All All
: medium normal
Assignee: Kohei Yoshida
URL:
Whiteboard: BSA target:3.7.0
Keywords:
: 52366 (view as bug list)
Depends on: 44720
Blocks:
  Show dependency treegraph
 
Reported: 2012-05-25 02:58 UTC by Morten Leikvoll
Modified: 2012-07-24 02:18 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Morten Leikvoll 2012-05-25 02:58:37 UTC
Problem description: 

Steps to reproduce:
1. Set cell A1 to 1
2. Set cell A2 to ="" (empty string)
3. Set cell A3 to =A1+A2
4. Set cell A4 to =value("")
5. Set cell A5 to =A1+B1 (B1 is an empty cell)
6. Set cell A6 to =value(B1)
Current behavior:
-A3 returns #VALUE
-A4 returns err:502
-A5 returns 1
-A6 returns 0

Expected behavior:
Openoffice 3.3 returns
-A3:returns 1
-A4:returns err:502
-A5:returns 1
-A6:returns 0

Conclusion:
An empty cell and a cell with empty sting should return either err:502 or 0, not a mix of both. My preference is 0 for historic reasons, but a setting to choose behaviour may be even better. I guess this topic is open to opinions.
(err:502 is "Invalid argument")

Platform (if different from the browser): 
              
Browser: Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E)
Comment 1 Eike Rathke 2012-05-25 03:46:08 UTC
Taking this.
Comment 2 Not Assigned 2012-07-18 15:29:21 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=a439cb5aba49d01df20f67a2c84b68542e4d3d5a

resolved fdo#50345 accept empty string as scalar numeric 0 argument
Comment 3 Not Assigned 2012-07-18 15:29:44 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=123fa79cb24dced9adea7ef4d007a4516c1555d4

unit test fdo#50345 accept empty string as scalar numeric 0 argument
Comment 4 Regina Henschel 2012-07-22 20:31:59 UTC
*** Bug 52366 has been marked as a duplicate of this bug. ***
Comment 5 Kohei Yoshida 2012-07-23 19:11:02 UTC
Bug 44720 is the primary bug for this compatibility issue.
Comment 6 Kohei Yoshida 2012-07-23 19:11:31 UTC
I'll take this.
Comment 7 Kohei Yoshida 2012-07-24 02:18:32 UTC
Actually I'll close this as a duplicate, because technically it is.

*** This bug has been marked as a duplicate of bug 44720 ***