[ 
https://issues.apache.org/jira/browse/PIG-5085?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15813614#comment-15813614
 ] 

Rohini Palaniswamy commented on PIG-5085:
-----------------------------------------

Till now have been suggesting users to convert the map to a bag with a udf and 
then FLATTEN it.

Below is a very short jython UDF example from 
http://chase-seibert.github.io/blog/2013/02/10/pig-hbase-flatten-column-family.html
{code}
@outputSchema("values:bag{t:tuple(key, value)}")
def bag_of_tuples(map_dict):
    return map_dict.items()
{code}

> Support FLATTEN of maps
> -----------------------
>
>                 Key: PIG-5085
>                 URL: https://issues.apache.org/jira/browse/PIG-5085
>             Project: Pig
>          Issue Type: New Feature
>            Reporter: Rohini Palaniswamy
>
>   I have come across users asking for this quite a few times. Don't see why 
> we should not support it with FLATTEN instead of users having to write a UDF 
> for that



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to