Bug 118878 - weird behaviour in formulas
Summary: weird behaviour in formulas
Status: RESOLVED INSUFFICIENTDATA
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
6.2.0.0.alpha0+
Hardware: All Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-07-22 08:32 UTC by Elmar
Modified: 2019-05-08 20:40 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
weird formula results (20.82 KB, application/vnd.oasis.opendocument.spreadsheet)
2018-07-22 08:34 UTC, Elmar
Details
The formulas in the first file were wrong. But still have a question (25.08 KB, application/vnd.oasis.opendocument.spreadsheet)
2018-07-22 09:13 UTC, Elmar
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Elmar 2018-07-22 08:32:33 UTC
Description:
Apologise: I cannot describe this better. You need to look at the example ods to see what I mean.

It happens in Calc v6.2dev and v5.1.6.2



Steps to Reproduce:
1. apply formulas data
2. get weird results
3.

Actual Results:
weird results

Expected Results:
should do what formula says


Reproducible: Always


User Profile Reset: No



Additional Info:
[Information automatically included from LibreOffice]
Locale: en-ZA
Module: SpreadsheetDocument
[Information guessed from browser]
OS: Linux (All)
OS is 64bit: yes

Only thing different is that this was done on an instance which was a clean install of Linux Mint Cinnamon 18.3

I am going to try it in other instances
Comment 1 Elmar 2018-07-22 08:34:54 UTC
Created attachment 143683 [details]
weird formula results
Comment 2 Elmar 2018-07-22 08:54:30 UTC
Apologies. Brain freeze gain. 
did not see when copying formulas that offset was wrong.
Comment 3 Elmar 2018-07-22 09:08:40 UTC
If a cellA1 has 64 (number in it) and I do a compare If(A1>"64","6S","??") it does not work even though strictly speaking, there should be no difference between number 64 and text 64.

Maybe a solution is to report an error when one is comparing a text string with a numeric value (number) in a cell.

What do you think?
Comment 4 Elmar 2018-07-22 09:13:37 UTC
Created attachment 143684 [details]
The formulas in the first file were wrong. But still have a question

I have corrected the formulas which were actually not producing weird results.

But please look at the comment in the bug notification.
Comment 5 Mike Kaganski 2018-07-22 12:45:40 UTC
(In reply to Elmar from comment #4)
> But please look at the comment in the bug notification.

Please always describe what you actually see. Because e.g. I don't know if I see that same as you, so it's impossible to test/confirm/suggest anything unless you not only highlight cells, but also write something like "I see 6S there, but expect it to be ??", or add screenshots, or otherwise make clear what is wrong.

E.g., opening the attachment 143684 [details] with Version: 6.1.0.2 (x64)
Build ID: b3972dcf1284967612d5ee04fea9d15bcf0cc106
CPU threads: 4; OS: Windows 10.0; UI render: default; 
Locale: ru-RU (ru_RU); Calc: CL,
I see this text that supposedly should describe me the problem:

> In this example, I am doing a simple age evaluation
> and then allocating a code based on the age. e.g. if
> under 14, 1C – a child; if <18 a teen (2T), etc.
> 
> Formula issue: see cell AA65
> 
> but do not understand why if I compare
> Numeric 64 to “64” (text 64) I get a different result

But when I scroll down to AA65 (which is marked yellow), I see it to have "??"; and that is kind of expected, because the comparison in it (=IF(Z66>64;"6S";"??")) only should give "6S" when Z66 is strictly greater than 64, but Z66 has 64.

And now I don't see anything that would help me to know if I see the same that you see (and then your question is unclear or your expectations are wrong), or you see a different picture (and there is a problem in your version or settings or profile something else).
Comment 6 Mike Kaganski 2018-07-22 12:55:05 UTC
(In reply to Mike Kaganski from comment #5)

A small correction (I got slightly confused when composed my comment 5, which doesn't invalidate its message): AA65 has formula =IF(Z65>64;"6S";"??") and result "??"; Z65 has 63; the result in AA65 is correct (as is in AA66 having "??", too, and in following cells having "6S").
Comment 7 raal 2018-08-01 15:07:19 UTC
(In reply to Mike Kaganski from comment #6)
> (In reply to Mike Kaganski from comment #5)
> 
> A small correction (I got slightly confused when composed my comment 5,
> which doesn't invalidate its message): AA65 has formula
> =IF(Z65>64;"6S";"??") and result "??"; Z65 has 63; the result in AA65 is
> correct (as is in AA66 having "??", too, and in following cells having "6S").

Elmar, please describe the problem. Tested with LO 6.2, I get correct results in AA65 and AA66. Thank you
Comment 8 Xavier Van Wijmeersch 2018-08-02 15:27:55 UTC
Elmar

I changed your formula to
=IF(NOT(X3>0);"??";IF(X3<14;"1C";IF(X3<18;"2T";IF(X3<26;"4A";IF(X3<65;"5M";IF(X3>64;"6S";"??"))))))
first: in the last IF i changed "64" to 64
second: three IF's did have the wrong row number; X4 and it needed to be X3
I used the second attachment

Version: 6.2.0.0.alpha0+
Build ID: 83d8331581ab43cf35325ca674cf62d4ba5dc5ad
CPU threads: 8; OS: Linux 4.14; UI render: default; VCL: kde4; 
Locale: nl-BE (en_US.UTF-8); Calc: group threaded
Comment 9 QA Administrators 2019-03-21 11:11:23 UTC Comment hidden (obsolete)
Comment 10 QA Administrators 2019-05-08 20:40:10 UTC
Dear Elmar,

Please read this message in its entirety before proceeding.

Your bug report is being closed as INSUFFICIENTDATA due to inactivity and
a lack of information which is needed in order to accurately
reproduce and confirm the problem. We encourage you to retest
your bug against the latest release. If the issue is still
present in the latest stable release, we need the following
information (please ignore any that you've already provided):

a) Provide details of your system including your operating
   system and the latest version of LibreOffice that you have
   confirmed the bug to be present

b) Provide easy to reproduce steps – the simpler the better

c) Provide any test case(s) which will help us confirm the problem

d) Provide screenshots of the problem if you think it might help

e) Read all comments and provide any requested information

Once all of this is done, please set the bug back to UNCONFIRMED
and we will attempt to reproduce the issue. Please do not:

a) respond via email 

b) update the version field in the bug or any of the other details
   on the top section of our bug tracker

Warm Regards,
QA Team

MassPing-NeedInfo-FollowUp