Re: Joining 3 tables in Pig

2013-04-26 Thread Raj hadoop
Thank you so much Bill. It helped me alot. On Thu, Apr 25, 2013 at 10:22 AM, Bill Graham wrote: > You'll need to do a 3-way join in two steps: > > A = load 'foo' as (col1, col2); > B = load 'bar' as (col1); > C = load 'bat' as (col1); > > AB = join A by col1, B by col1; > ABC = join AB by A.col

BinCond is not working

2013-04-26 Thread soniya B
Hi Friends, I have registered piggy bank.I tried to to use BinCond funcation but it is not working . Any one can suggest why it not working?

Re: BinCond is not working

2013-04-26 Thread Russell Jurney
Paste code? On Apr 26, 2013 10:05 AM, "soniya B" wrote: > Hi Friends, > > I have registered piggy bank.I tried to to use BinCond funcation but it is > not working . Any one can suggest why it not working? >

Re: BinCond is not working

2013-04-26 Thread soniya B
Hi Russell, Actually i am trying to convert sql queries to PIG script. SELECT SUP1,DEP_NO, CASE WHEN SVT1= 'Y' THEN 'A' WHEN SVT2= 'Y' THEN 'B' WHEN SVT3 = 'Y' THEN 'C' WHEN SVT4= 'I' THEN 'D' WHEN SVT5 = 'J' THEN 'E' ELSE 'F' END FROM PEP_ACC_Details I am trying to convert above stateme

Re: BinCond is not working

2013-04-26 Thread Russell Jurney
What is the error? Russell Jurney http://datasyndrome.com On Apr 26, 2013, at 11:43 AM, soniya B wrote: > Hi Russell, > > Actually i am trying to convert sql queries to PIG script. > > > SELECT SUP1,DEP_NO, > > CASE WHEN SVT1= 'Y' THEN 'A' > > WHEN SVT2= 'Y' THEN 'B' > WHEN SVT3 = 'Y' THEN 'C'

Re: BinCond is not working

2013-04-26 Thread Russell Jurney
Did you do this first? register piggybank.jar *define BinCond org.apache.pig.piggybank.evaluation.decode.BinCond();* Russell Jurney http://datasyndrome.com On Apr 26, 2013, at 11:43 AM, soniya B wrote: Hi Russell, Actually i am trying to convert sql queries to PIG script. SELECT SUP1,DEP_NO

Re: BinCond is not working

2013-04-26 Thread soniya B
Hi Russell, I have already executed below one but no luck register piggybank.jar *define BinCond org.apache.pig.piggybank.evaluation.decode.BinCond();* I am getting syntax error as mismatched input '(' expecting SEMI_COLON On Sat, Apr 27, 2013 at 12:44 AM, Russell Jurney wrote: > Did you do

Re: BinCond is not working

2013-04-26 Thread soniya B
Hi Russell, I have already executed below one but no luck register piggybank.jar *define BinCond org.apache.pig.piggybank.evaluation.decode.BinCond();* I am getting syntax error as mismatched input '(' expecting SEMI_COLON Is the syntax correct that i have written? Thanks Soniya On Sat, Apr