Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Threaded View
Pig >> mail # user >> Newbie question on bags/tuples


Copy link to this message
-
RE: Newbie question on bags/tuples
You probably needs a UDF that takes a bag and produces a tuple that combines all tuples in the bag. I'm not sure if there is such a UDF in Piggybank. The flatten clause doesn't do what you want.

Thanks,
Xuefu

-----Original Message-----
From: Mark [mailto:[EMAIL PROTECTED]]
Sent: Friday, March 11, 2011 9:26 PM
To: [EMAIL PROTECTED]
Subject: Newbie question on bags/tuples

Sorry if butcher the terminology I'm still new to Pig but Ill try my best.
Given a bag of tuples how can I create a flattened version of all the tuples?
For example say I have {(1), (2), (3)} how can I produce? (1,2,3).

Thanks
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB