[
https://issues.apache.org/jira/browse/ASTERIXDB-2667?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Hussain Towaileb updated ASTERIXDB-2667:
----------------------------------------
Description: The string functions concat, string_concat and string_join
have a very similar behavior, they can be sharing the same code base instead of
having a different evaluator for each function (was: CONCAT2 is similar to
CONCAT function, which simply a string concatenation of all the provided
parameters, however, it allows specifying a separator to be used between the
concatenated strings as a first argument, and accepts arrays of strings that
get flatted and concatenated.
If a single argument only is provided with the separator, then the separator is
not used, and only a single string is returned.
Examples:
{code:java}
concat2("-", "1", "2") -> "1-2"
concat2("-", "1", ["2", "3"]) -> "1-2-3"
concat2("-", "1") -> "1"
concat2("-", ["1"]) -> "1"
{code})
> Share code between string functions
> -----------------------------------
>
> Key: ASTERIXDB-2667
> URL: https://issues.apache.org/jira/browse/ASTERIXDB-2667
> Project: Apache AsterixDB
> Issue Type: Improvement
> Components: FUN - Functions
> Affects Versions: 0.9.4.1
> Reporter: Hussain Towaileb
> Assignee: Hussain Towaileb
> Priority: Major
> Fix For: 0.9.5
>
>
> The string functions concat, string_concat and string_join have a very
> similar behavior, they can be sharing the same code base instead of having a
> different evaluator for each function
--
This message was sent by Atlassian Jira
(v8.3.4#803005)