[
https://issues.apache.org/jira/browse/PIG-2242?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Ashutosh Chauhan updated PIG-2242:
----------------------------------
Resolution: Fixed
Release Note:
TOKENIZE now can take an optional second argument as delimiter.
Usage:
{code}
a = load 'data' as (f1:chararray);
b = foreach a TOKENIZE (f1,'||');
dump b;
{code}
Status: Resolved (was: Patch Available)
Patch checked-in. Thanks, Mark!
Opened PIG-2245 for the followup.
> Allow the delimiter to be specified when calling TOKENIZE
> ---------------------------------------------------------
>
> Key: PIG-2242
> URL: https://issues.apache.org/jira/browse/PIG-2242
> Project: Pig
> Issue Type: Improvement
> Components: impl
> Affects Versions: 0.8.1, 0.9.0
> Reporter: Mark Roddy
> Assignee: Mark Roddy
> Priority: Minor
> Fix For: 0.10
>
> Attachments: tokendelim.diff
>
>
> The TOKENIZE function is a wrapper around the Java StringTokenizer class.
> The delimiter argument is currently hard coded as " \",()*", and it is
> impossible to specify an alternative delimiter.
> The delimiter can be added as an optional argument to TOKENIZE which will
> preserve backwards compatibility while allowing users to specify their own
> delimiter chars.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira