There are 2 tables:
EMP : EmpId, Ename, Sal, DeptId
DEPT : DeptId, Dname
Write a query to find out emp names and their department names. if any emp has null in Deptid the it shows
?No Department?.
Write a query to find out those department names which
has no employee.
Write a query to find out those employees whose salary
is greater than their department?s average salary.
Answer Posted / humera
Answer Q # 37
select e.ename,d.dname from emp e left outer join dept d on
e.deptid = d.deptid
| Is This Answer Correct ? | 1 Yes | 4 No |
Post New Answer View All Answers
give idea for creating screen in abap
How to merge Action Form with Dyna Action Form in Struts.
where is available in this mantis toturials?
how to work search engine? plz detail answer me.
how pseudo column works?
WHat is execution in manual testing and when will we start execution and what language we use in execution
how do i add a column dynamically in a table by using java application?
How to set on/off a group of indicators in a single statement?
SELECT A~FTRMI A~AUFNR B~MATNR D~MAKTX B~PSMNG B~WEMNG C~MTART E~CHARG C~MATKL C~SPART R~BWART R~CHARG R~MATNR E~BWART R~BDMNG INTO TABLE ITAB FROM AFKO AS A INNER JOIN AFPO AS B ON A~AUFNR = B~AUFNR * INNER JOIN AFVC AS A1 ON A~AUFPL = A1~AUFPL AND B~DWERK = A1~WERKS INNER JOIN MARA AS C ON B~MATNR = C~MATNR INNER JOIN MAKT AS D ON C~MATNR = D~MATNR INNER JOIN MSEG AS E ON B~MATNR = E~MATNR AND A~AUFNR = E~AUFNR AND B~DWERK = E~WERKS INNER JOIN RESB AS R ON A~AUFNR = R~AUFNR AND E~AUFNR = R~AUFNR AND R~RSNUM = A~RSNUM AND R~WERKS = E~WERKS AND R~BAUGR = E~MATNR INNER JOIN MARA AS C1 ON R~MATNR = C1~MATNR WHERE A~FTRMI IN S_DATE AND A~AUFNR IN S_AUFNR AND C~MTART IN S_TYPE AND C~MATKL = 'T' AND R~BWART ='261' AND E~BWART = '101' AND R~XWAOK ='X' AND B~DWERK = '2000' AND R~XLOEK EQ SPACE AND E~KZBEW ='F' AND D~SPRAS = 'E' AND R~KZEAR = 'X' AND C~MATNR IN S_MATNR. This query gives repetative records from RESB.There must be some common field which i am not taking thats why its giving repetative records. If u find any solution pls lety me know ASAP. Thanks Swati Ghadge
What is easiest way to get the PL/i compiler,I didn't have found the compiler in my library. Is there any extra cost if we want to access the PL/1 programs?Actually we r having Mainframe rented training Ids
how can i create report in abap to insert data in table pa0002 using insert command
Bonjour, svp je veut voir comment envoyer un mail en java et comment changer le droit d'accé d'un fichier en java: de lecture en lecture/écriture et merci d'avance ;)
I want to insert date in the form of yyyy-mm-dd... if any changes happen while inserting date format want to show error meg...any one can solve this..??
how to convert hashmap to arraylist with iteration
Define distributed queries. can you explain me as soon as possible