Apache OpenOffice (AOO) Bugzilla – Issue 120076
[From Symphony]2+ and 2 will be filter out at the same time
Last modified: 2012-07-20 01:41:36 UTC
Created attachment 78454 [details] sample Build: AOO 3.4 Steps: 1. Open attached sample file 2. Filter out numerical 2 Defect: string "2+" is also shown
I am investigating this issue.
Created attachment 78456 [details] make the “2+”、“2-” as a string Root cause:AOO does not make the "2+"/"2-" as a string when filter data in a column. Resolve method: If the condition is a number followed by '+'/'-',then make is as a string.
The patch works as described but I am not yet convinced that there is a problem that has to be solved. 2+ does not look like a number (to me it looks like a German school grade), so why should it be treated like one? Also, the drop down box of the "filter" button has two different entries for "2" and "2+". If they are treated differently there then why treat them differently in the cells below?
I am confused by Andre's comment. In the opinion,if the cells contains such string "2+","2-",and "2". if user selects "2" in the data filter, the filter result should be all of them ("2","2+","2-")?
and if you open the sample document,the cell type in "2+" is string ,not number. so "2+" must be made as a string when do filter function.
I am still not convinced that a filter pattern "2" should match strings like "2+" and "2-". Unless it is treated as a substring match. In that case it should also match strings like "this contains a 2" or "2&&1". Why have special handling of "2+" and "2-" but nothing else?
I see an error the other way round. If you select item 2+ from the filter, it will match rows too, that have the number 2. I see the error only with entry 2+ not with entry 2-
No matter what you may do,should think what is the result that the user want to get. In this sample, if user select "2+",the result should only be the items of "2+", not other items.
That is basically my point. If you select "2+" in the filter then only "2+" rows should be displayed. And if you select "2" as filter string then only "2" rows should be displayed. Unless all rows that contain the filter string should match. So the important question (I am not a Calc expert and can not answer it myself) is whether the filter matches rows that are a) equal to or b) contain the filter string.
the answer is a) equal to