Bug 131927 - Help fails to explain variable use of criteria parameter in sumif()
Summary: Help fails to explain variable use of criteria parameter in sumif()
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Documentation (show other bugs)
Version:
(earliest affected)
6.4.2.2 release
Hardware: All All
: medium enhancement
Assignee: Olivier Hallot
URL:
Whiteboard: target:25.8.0
Keywords:
Depends on:
Blocks: Help-Changes-Features
  Show dependency treegraph
 
Reported: 2020-04-06 11:11 UTC by Burg
Modified: 2025-02-20 22:33 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 Burg 2020-04-06 11:11:43 UTC
The sumif() function allows cell reference in its 'criteria' parameter, like:

SUMIF(G4:G66;"="&G68;D4:D66)
where G68 contains the index, for example numbers 1,2,3.
According to the (en) help each function needed specific "=1", "=2" and "=3" criteria.
I only found the above solution in online forums - for Excel ;-) - but it works also in LO.

Solution: Add the ".."&cell-reference  Option to the Help text.
Comment 1 Ming Hua 2020-05-02 11:58:46 UTC
Since you are talking about the English help text, it sounds like a documentation issue instead of a localization one to me.

Let's change the component and ping the documentation people and see what they say.
Comment 2 Burg 2020-05-02 13:56:50 UTC
Fine with me, I did not see the 'documentation' option.
Comment 3 Buovjaga 2020-08-24 19:56:58 UTC
Ok, the section is https://help.libreoffice.org/latest/en-US/text/scalc/01/04060106.html#Section15

If you want, you can propose the explanation that should be added and the location of where it should be inserted.
Comment 4 fpy 2024-03-15 11:19:05 UTC
I guess the point here is just that only 1 example is given,
because the text clearly says :  A criterion is a *single cell Reference*, Number or Text


For the sake of closing this "bug", I'm adding a link to COUNTIF, to emphasize it  gives more examples.

See also many more examples here :
https://wiki.documentfoundation.org/Documentation/Calc_Functions/SUMIF
Comment 5 Burg 2024-03-16 14:13:03 UTC
R U Sirius? 
Four years after reporting this deficiency in the help files, the best solution is to add a link to another function with the same situation?

Help is there to -explain-, not to give examples.
Add the proposed text, then you can close this bug.
Comment 6 Olivier Hallot 2025-01-16 18:55:27 UTC
Actually - and this is not clear in the Help text - Criterion must result in a string expression or cast into a string expression.

So whatever formula you put in Criterion, it works as long as it results in a string.

in case of comment#0 

SUMIF(G4:G66;"="&G68;D4:D66)

criterion is concatenation of "=" with whatever is the contents of G68.
Comment 7 Burg 2025-01-17 10:19:15 UTC
Ok, fine - so what's wrong with clarifying this behaviour in the help text?
Comment 8 Commit Notification 2025-01-17 11:39:45 UTC
Olivier Hallot committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/help/commit/c0b77292ca59b964feb3d039e9cb9e3adb927c96

tdf#131927 Clarify criterion as string expression in SUMIF