Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Q1.all the depts which has more then 10 empls? Q2.all the
dept which does not have any emply? Q3 all the emp which
does not have any dept? Q4 get all the emply detais with
the dept details it dept is exit otherwise any emp details?
Q5 how to debugg the dynamic sql and packages?

Answer Posted / krish

1)select deptno,count(*)
from emp having count(*)=0 group by deptno;
2)select deptno,count(*)
from emp having count(*)>10 group by deptno;
3)select empname from emp where deptno is null;
4)select emp.deptno,emp.ename,dept.deptno,dept.dname
from emp,dept
where emp.deptno=dept.deptno(+);

Is This Answer Correct ?    2 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Are ddl triggers fired for ddl statements within a pl/sql code executed using the dbms.sql package?

1080


Which tcp/ip port does sql server run on? How can it be changed? : Sql dba

980


What is the maximum rows in csv?

911


Does normalization improve performance?

1019


what is sql server agent? : Sql dba

1082


Can we use rowid as primary key?

965


How can you load multi line records? : aql loader

1065


What is a constraint?

998


How many types of triggers are there in pl sql?

1050


Which is better varchar or nvarchar?

977


Write a query to display the current date in sql?

1004


How do you rank data in sql?

982


Is sql a dbms?

978


What are hotfixes and patches?

930


What is pivot query?

1055