Issue 120076 - [From Symphony]2+ and 2 will be filter out at the same time
Summary: [From Symphony]2+ and 2 will be filter out at the same time
Alias: None
Product: Calc
Classification: Application
Component: editing (show other issues)
Version: 3.4.0
Hardware: All All
: P3 Normal (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
Depends on:
Reported: 2012-06-25 05:30 UTC by Yan Ji
Modified: 2012-07-20 01:41 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---

sample (7.72 KB, application/vnd.oasis.opendocument.spreadsheet)
2012-06-25 05:30 UTC, Yan Ji
no flags Details
make the “2+”、“2-” as a string (1.10 KB, patch)
2012-06-25 07:59 UTC, zhaoshzh
aoo.zhaoshzh: review?
Details | Diff

Note You need to log in before you can comment on or make changes to this issue.
Description Yan Ji 2012-06-25 05:30:37 UTC
Created attachment 78454 [details]

Build: AOO 3.4
1. Open attached sample file
2. Filter out numerical 2

Defect: string "2+" is also shown
Comment 1 zhaoshzh 2012-06-25 06:48:22 UTC
I am investigating this issue.
Comment 2 zhaoshzh 2012-06-25 07:59:15 UTC
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.
Comment 3 Andre 2012-07-09 13:45:43 UTC
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?
Comment 4 zhaoshzh 2012-07-16 06:30:08 UTC
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-")?
Comment 5 zhaoshzh 2012-07-16 06:32:43 UTC
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.
Comment 6 Andre 2012-07-16 07:27:35 UTC
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?
Comment 7 Regina Henschel 2012-07-16 13:06:15 UTC
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-
Comment 8 zhaoshzh 2012-07-17 01:32:08 UTC
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.
Comment 9 Andre 2012-07-18 13:17:17 UTC
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.
Comment 10 zhaoshzh 2012-07-20 01:41:36 UTC
the answer is 
a) equal to