Grokbase Groups Pig user April 2011
FAQ
Hello,

is it possible to return a bag from UDF?


When I def. my python UDF like this... it simply doesnt work....

@outputSchema("y:bag{key:int, t:tuple(len:int,word:chararray)}")
def toTuple(bag):



2011-04-24 16:06:08,794 [main] ERROR org.apache.pig.tools.grunt.Grunt -
ERROR 2998: Unhandled internal error. Error parsing schema for script
function from the decorator
org.apache.pig.impl.logicalLayer.parser.ParseException: Encountered " "bag"
"bag "" at line 1, column 3.
Was expecting one of:
"int" ...
"long" ...
"float" ...
"double" ...
"chararray" ...
"bytearray" ...
"int" ...
"long" ...
"float" ...
"double" ...
"chararray" ...
"bytearray" ...



Thanks.

Search Discussions

Discussion Posts

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 1 of 4 | next ›
Discussion Overview
groupuser @
categoriespig, hadoop
postedApr 24, '11 at 2:06p
activeApr 24, '11 at 4:01p
posts4
users1
websitepig.apache.org

1 user in discussion

Pob: 4 posts

People

Translate

site design / logo © 2022 Grokbase