[
https://issues.apache.org/jira/browse/PIG-1420?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12899597#action_12899597
]
Dmitriy V. Ryaboy commented on PIG-1420:
----------------------------------------
Yeah, let's plan to add a way to specify a vararg in the schema in 0.9.
In the meantime, what do we do with concat? Option 1: leave broken (only works
for 2 arguments). Option 2: take out arg2func mapping, and have people who want
to concat strings use StringConcat explicitly.
Actually, there is an option 3, which makes more sense than option 2: make
CONCAT actually do what StringConcat does, and introduce BinConcat (since it
seems unlikely people are actually concatting bytearrays...).
> Make CONCAT act on all fields of a tuple, instead of just the first two
> fields of a tuple
> -----------------------------------------------------------------------------------------
>
> Key: PIG-1420
> URL: https://issues.apache.org/jira/browse/PIG-1420
> Project: Pig
> Issue Type: Improvement
> Components: impl
> Affects Versions: 0.8.0
> Reporter: Russell Jurney
> Assignee: Russell Jurney
> Fix For: 0.8.0
>
> Attachments: addconcat2.patch, PIG-1420.2.patch
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> org.apache.pig.builtin.CONCAT (which acts on DataByteArray's internally) and
> org.apache.pig.builtin.StringConcat (which acts on Strings internally), both
> act on the first two fields of a tuple. This results in ugly nested CONCAT
> calls like:
> CONCAT(CONCAT(A, ' '), B)
> The more desirable form is:
> CONCAT(A, ' ', B)
> This change will be backwards compatible, provided that no one was relying on
> the fact that CONCAT ignores fields after the first two in a tuple. This
> seems a reasonable assumption to make, or at least a small break in
> compatibility for a sizable improvement.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.