https://bz.apache.org/bugzilla/show_bug.cgi?id=65230

            Bug ID: 65230
           Summary: TRIM function: implementation incomplete
           Product: POI
           Version: 5.0.0-FINAL
          Hardware: All
                OS: All
            Status: NEW
          Severity: minor
          Priority: P2
         Component: SS Common
          Assignee: dev@poi.apache.org
          Reporter: gerard.du...@externe.bnpparibas.com
  Target Milestone: ---

The current implementation of the TRIM function just "String.trim()" the input.
This is not enough.


Indeed, a quick test within Excel of Office 365, shows that this function also
reduces duplicated spaces between words to simple ones.
So this behavior should be replicated within the TextFunction class.

Test case:
Just add the following line in TestTrim.testBasic():
confirmTrim(new StringEval("hi  there"), "hi there");

This bug applies to the 4.1.2-FINAL version too.



On a sidenote, the online documentation does not mention this specific
behavior:
https://support.microsoft.com/en-us/office/trim-function-410388fa-c5df-49c6-b16c-9e5630b479f9
I have sent them a feedback on this matter.
The inline documentation is fortunately correct, at least the French one.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org
For additional commands, e-mail: dev-h...@poi.apache.org

Reply via email to