GeekInterview.com
Answered Questions

3 way join with different column names.

Asked By: vital_parlsey | Asked On: Mar 1st, 2012

Hi, i have 3 files each having 2 cols e.G file1 empid deptid 1 100 2 200 3 200 4 100 5 300 file2 empid salary 1 10 2 20 3 30 4 40 5 ...

Answered by: PLMS on: Mar 29th, 2013

Step 1: File1 - left outer Join {Key- empid} with -File2 Step 2: The above output flow should be sort{PBKS-if multifile} based on key empid Step 3: The step 2s o/p flow to be left outer joi...

Answered by: Malini on: Apr 3rd, 2012

Code
  1.   SELECT C.DEPTNAME,sum(B.SALARY) FROM FILE1 A ,FILE2 B ,FILE3 C
  2.   WHERE A.EMPLID=B.EMPLID AND A.DEPTID=C.DEPTID
  3.   GROUP BY C.DEPTNAME

Interview Question

 Ask Interview Question?

 

Career Counselling

 Have Career Question?

 Ask Chandra

 Ask Only Career questions.

Follow us: