Issue 93128 - Data validity works incorrectly with criteria "Allow text length" for numbers
Summary: Data validity works incorrectly with criteria "Allow text length" for numbers
Status: REOPENED
Alias: None
Product: Calc
Classification: Application
Component: code (show other issues)
Version: OOO300m3
Hardware: All All
: P3 Trivial (vote)
Target Milestone: 4.0.0
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
: 117802 (view as issue list)
Depends on:
Blocks: 84405
  Show dependency tree
 
Reported: 2008-08-26 09:16 UTC by amy2008
Modified: 2013-01-29 21:41 UTC (History)
9 users (show)

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


Attachments
Add patch (611 bytes, patch)
2012-07-25 05:05 UTC, Zhang Lu
hdu: review+
Details | Diff

Note You need to log in before you can comment on or make changes to this issue.
Description amy2008 2008-08-26 09:16:00 UTC
In OOo300_m3_EN on WinXP.

To reproduce:
1 Select the cells for which you want to define a new validity rule
2 Choose Data - Validity
3 On the Criteria tab page, enter the conditions for new values entered into 
cells
4 In the Allow field, select "Text length"
5 In the Data field, select such as "less than"
6 In the Value field, enter into "10"

Result:
If you enter "11111" into the cells for which you want to define a new 
validity rule, there is a error message "Invalidate value".

Expectation:
we can enter anything into the cells

Help contents:
"Text Length" stipulates that cells are allowed to contain text only.

If I formatted the cells as text, then define a new validity rule for thes 
rules, now we can enter numbers into these cells without any error messages.
Comment 1 kpalagin 2010-11-23 08:48:42 UTC
I am experiencing the same issue (in 2.4.1, 3.1.1 and DEV300m93).
Please consider this issue for 3.4.
Comment 2 Li Lin Yi 2012-07-18 10:01:52 UTC
*** Issue 117802 has been marked as a duplicate of this issue. ***
Comment 3 Zhang Lu 2012-07-19 06:47:29 UTC
I am working on this defect.
Comment 4 Zhang Lu 2012-07-25 05:05:31 UTC
Created attachment 78719 [details]
Add patch

Root cause: There is no flow to handle a real number when selecting string length operation
Solution: if operation is string length type, get the number's length, and consider it as a string.
Comment 5 SVN Robot 2012-08-01 13:47:58 UTC
"hdu" committed SVN revision 1367992 into trunk:
#i93128# fix data validity check for criteria "Allow text length" and numeric...
Comment 6 hdu@apache.org 2012-08-01 13:51:24 UTC
Thanks a lot! Applied into trunk.
Comment 7 SVN Robot 2012-10-11 14:42:37 UTC
"hdu" committed SVN revision 1397088 into trunk:
#i93128# was fixed so the auto test ValidityDialogSetting::testAllowLessThanT...
Comment 8 binguo 2012-11-14 03:00:11 UTC
Verified on Aoo_Trunk_20121109.1800 rev 1407366
run the following steps:
1 Select the cells for which you want to define a new validity rule
2 Choose Data - Validity
3 On the Criteria tab page, enter the conditions for new values entered into 
cells
4 In the Allow field, select "Text length"
5 In the Data field, select such as "less than"
6 In the Value field, enter into "10"

Result:
If you enter number OR text which length of them are equal or greater than "10" such as "1234567890" or "abcdefghijh" into the cells for which you want to trigger validity rule, but no error message 

Expectation:
there should be error message saying "Invalidate value".

NOTES:
In MS Excel 2003 side, if you set rule "Text length" "less than"  "10" to the cells, the cells can not input number OR text which length of them are equal or greater than "10".

So Reopen it.