Bug 59309 - One cell containing text in a string of addends causes calc to return #VALUE!.
Summary: One cell containing text in a string of addends causes calc to return #VALUE!.
Status: CLOSED NOTABUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
3.5.7.2 release
Hardware: Other Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Cell-Formula
  Show dependency treegraph
 
Reported: 2013-01-13 05:08 UTC by trj
Modified: 2020-09-23 12:39 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
sample for OP, samples for questionable results (12.29 KB, application/vnd.oasis.opendocument.spreadsheet)
2020-07-04 10:02 UTC, b.
Details

Note You need to log in before you can comment on or make changes to this bug.
Description trj 2013-01-13 05:08:58 UTC
Attached spreadsheet shows simple addition in cell F25 to fail and return #VALUE! when one of the terms contains text. The same happens with subtraction. Note, by contrast, that the function SUM is able to tolerate text-containing cells in its parameter list. Possibly noteworthy is the fact that functions such as MIN, MAX, AVERAGE, &c, also all tolerate text-containing cells in their parameter lists.

LO 3.5.7.2; Build ID: 3215f89-f603614-ab984f2-7348103-1225a5b.

OO calc 3.3.0 behaves in the same manner.
Comment 1 ign_christian 2013-06-10 06:43:46 UTC
No attached file here. Please try again to attach & explain how to see that problem.
Comment 2 QA Administrators 2014-02-02 02:06:23 UTC Comment hidden (obsolete)
Comment 3 QA Administrators 2014-02-26 19:30:54 UTC Comment hidden (obsolete)
Comment 4 b. 2020-07-04 10:02:47 UTC
Created attachment 162631 [details]
sample for OP, samples for questionable results

reopening as imho it's a valid question / valid conflict ... 

seeing it different to the OP, '#VALUE!' can be handeled by a user, silent semi intelligent 'help' is dangerous, 

for or against all highlighted results can be argued from different and conclusive points of view: 
- you shouldn't calculate text, 
- you should convert strings to numbers if applicable, 
- '+' and 'SUM' should have same result, 
- omission of arguments should be visible to the user
- conversion of arguments should be visible to the user
- school math standard, 
- TDF math standard, 
- excel compatibility, 
and plenty more ...

the essential point is: 

while we are arguing about flavours of special points calc produces irritated users and wrong results ‚in the field’, 
(these wrong results may be right from the one or other point of view, that doesn’t help a user who had conclusive other expectations) 

the question of all questions is: 'where do we want to go'?

and there could hardly be any other answer than: 
'informed users which can handle the results’, 

(it’s a little as with democracy, informed people could handle that, if after elections 'politics' follows 'superior aspects' or if the flood of information overwhelms the individual because of the size of the administrative unit or information is manipulated, democracy is a worthless fraud)

and ex$el compatibility: yes, it’s an important point, but should not spread errors or hinder progress, otherwise calc is blocked from ever becoming better than ex$el

thus any formula which gets arguments or parameters which do not fully fit the type needed should mark it’s results accordingly, 
and these warnings should spread downstreams (it’s a spreadsheet isn’t it?)
text proposal: ‚unusual or conflicting types detected within the arguments used for this cell, conversion and / or omission took place, pls. double check your results‘, 

imho ex$el started going that path, i don't know if already with warnings for arguments in formulas, but they started marking cells with 'deviating formatting' years ago, which is an attempt to produce 'informed users' and thus the right direction.
Comment 5 b. 2020-09-11 09:28:32 UTC
did i miss re-opening? or did someone re-close?
Comment 6 Roman Kuznetsov 2020-09-22 20:19:15 UTC
(In reply to b. from comment #5)
> did i miss re-opening? or did someone re-close?

I think it's an enhancement, but I can't invent a summary for it =(

Eike, what's your opinion here?
Comment 7 Eike Rathke 2020-09-23 12:39:19 UTC
Whether or if and how text is accepted as operands to mathematical operators entirely depends on the settings under Tools -> Options -> Calc -> Formula, Detailed Calculation Settings; if you check Custom settings several modes are available for conversion from text to number. Always #VALUE! is recommended to spot data errors early, but that's not what some other software does and not what is used in legacy documents so not the default (yet?) but the awkward "also locale dependent" instead.. See help https://help.libreoffice.org/latest/en-GB/text/shared/optionen/detailedcalculation.html

> - '+' and 'SUM' should have same result, 
No. By definition SUM, AVERAGE, MAX, MIN, ... and other functions accepting cell ranges as number sequences *ignore* all text cells.

Not a bug.