Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Threaded View
Pig >> mail # user >> Fwd: Advice :: Possible commit

Copy link to this message
Fwd: Advice :: Possible commit
Hi Users,

I've been trying to follow the procedure described in the following page:
https://cwiki.apache.org/confluence/display/PIG/HowToContribute and sent an
email to the pig development mailing list in order to get some kind of
approval for the commit that I'm proposing, however this far I have the
feeling that it might not be getting in consideration even though I got a
reply (No response since more than 10 days ago). Could you give me some
advice in what should be the next steps, share any previous experience
about the contribution process or provide me the email of some key


On Thu, Sep 5, 2013 at 3:51 PM, Alan del Rio <[EMAIL PROTECTED]> wrote:

> Hi Alan,
> Here are my answers:
> 1) Why did you try to use RANK?
> I needed to create a second attribute in order to generate a one to one
> relationship between the two data bags, names and ids. RANK allowed me to
> generate a unique sequence  per data bag item according to the tuple
> position within the bags after using FLATTEN so that I could have the
> following:
> {{record_id:(00001),rank_B1:(1),name:(ALAN)}, {record_id:(00001),
> rank_B1:(2),name:(SARAI)}}
> {{record_id:(00001),rank_B2:(1),id:(00007)},{record_id:(00001),
> rank_B2:(2),id:(00008)}}
> and then try to get something like this (two records):
> {
>       {record_id:(00001),name:(ALAN),id:(00007)},
>       {record_id:(00001),name:(SARAI),id:(00008)}
> }
> using record_id and rank_B1,rank_B2 to join them. In short RANK gave
> consecutive numbers for joining purposes. Like I mentioned it worked well
> generating bags B11 and B22, but when I try to join them I got a run time
> error during map reduce.
> 2) The semantics here aren't clear to me.  record_id appears to be crossed
> with name and id but name and id appear to be chosen in order
> The problem that I'm dealing with is related to nested entries. The
> example record (0001) contains a relation one to many with its attribute
> names and besides that each name is associated to an id within the ids
> attribute. And all this associations need to be dumped in a table with the
> following structure.
> record_id-------name_id (id)--------name.
> This is not cross semantics, actually I had to develop the NLET function
> to avoid a cross product. Considering that the example record should only
> output 2 records. Number of records = 1 * number of items within the data
> bag (ids or names ,which is the same number).
> 3) I'm not familiar with the name NLET.Does that refer to a particular
> function or algorithm?
> Not really, I just wanted something that could sound similar to the word
> "TRIPLET" which refers to a set of items I replaced TRIP with the letter N
> because the function can generate sets of N number of items, depending on N
> number of data bags , maybe I should just call it SET : P but didn't want
> any issue with possible reserved words.
> By the way the data source of the bag A is a record that uses JSON  where
> it is common to see this kind of nested data.
> Best, Alan
> On Wed, Sep 4, 2013 at 10:05 AM, Alan Gates <[EMAIL PROTECTED]> wrote:
>> A few questions:
>> 1) Why did you try to use RANK?  I don't see how rank is part of this.
>> 2) The semantics here aren't clear to me.  record_id appears to be
>> crossed with name and id but name and id appear to be chosen in order.  If
>> this is join semantics I'd have expected two more entries in B, one with
>> (1, Alan, 8) and one with (1, Sarai, 7).  If you were just taking each
>> element in order I'd have expected the last row to be (null, Sarai, 8)
>> instead.
>> 3) I'm not familiar with the name NLET.  Does that refer to a particular
>> function or algorithm?
>> Alan.
>> On Aug 31, 2013, at 6:20 PM, Alan del Rio Mendez wrote:
>> > Hi Dev Team,
>> >
>> > I developed a UDF to handle the following situation on pig 10.0 and
>> want to
>> > see if I could contribute with it to the project.
>> >
>> > Let us consider a BAG "A" with the following data: