Bug 64633 - [PATCH] Support of function TEXTJOIN
Summary: [PATCH] Support of function TEXTJOIN
Status: NEW
Alias: None
Product: POI
Classification: Unclassified
Component: SS Common (show other bugs)
Version: unspecified
Hardware: All All
: P2 enhancement (vote)
Target Milestone: ---
Assignee: POI Developers List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-07-30 17:40 UTC by David Gordon
Modified: 2020-07-30 17:40 UTC (History)
0 users



Attachments
Implementation of TEXTJOIN (2.65 KB, application/x-gzip)
2020-07-30 17:40 UTC, David Gordon
Details

Note You need to log in before you can comment on or make changes to this bug.
Description David Gordon 2020-07-30 17:40:27 UTC
Created attachment 37377 [details]
Implementation of TEXTJOIN

TEXTJOIN was added to Excel in 2016.  It's used to concatenate strings with a specified delimiter, and to optionally exclude arguments evaluating as empty:

https://support.microsoft.com/en-us/office/textjoin-function-357b449a-ec91-49d0-80c3-0e8fc845691c

The attached patch adds support for the TEXTJOIN function, as well as a suite of unit tests for it.

First time submitting a POI patch, so please let me know if I've done something incorrectly and I'm happy to fix it!  Specifically, I wasn't sure the best way to bind the new function class to the function name, so I cribbed off another patch that added a new function via a binding in AnalysisToolPak.createFunctionsMap.

The patch was created against trunk, but for my own project's use, I've applied it back to 4.1.2, and that seems to work fine as well.

See also bug 60924.  I filed this separately in the interest of an easy merge since that one is a fairly old open bug with many functions listed, but if it's better to include it in there, that works too.