Sunday, 15 April 2012

hadoop - What exactly does the double colon mean in Pig? -


When I use DESCRIBE , I see too many double colons in pig production Is not, and it is not clearly what they mean.

For example, after grouping and leveling, I see something like this:

Key :: Supervisor: chararray, key :: endpoint: chararray. ..

At some point I had grouped the supervisor and end point, changed the group's tuple to 'key', and then was refailed. So, what exactly does the double colon mean, and the first relation (key? Observer?)

In your question, :: is a disputed operator and it is used to identify field names after JOIN, Cogprop, Cross or Flat operator. You can find an example of using different operators.

In your case, you have two field observers and end points and both are identified with key aliases, which means both supervisors and end points are referenced in the same aliases, the other "inspector and end point"

I think that you have used something below: some_statement_with_observerID_and_endpoint otherkey = some_statement_with_observerID_and_endpoint

give you on that basis Something similar to the one found here is:

  key :: Supervisor ID: Charray, Key :: End point: Charray, ...   

The above sentence means the supervisor and you can see the end point is not the surname of the other part of the main alias

No comments:

Post a Comment