Table Student has 3 columns,Student_id,Student_Name &
Course_Id. Table Course has 2 columns, Course_Id &
Course_Name.Write a query to listdown all the Courses and
number of student in each course.

Answer Posted / neo28

select Course_Id, Course_Name, count(Student_id) from
(
select c.Course_Id, c.Course_Name, s.Student_id
from Student s, Course c
where s.Course_Id(+) = c.Course_Id
) group by Course_Id
order by Course_Id;

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is a database transaction? : Sql dba

684


How to write html code in pl sql?

687


what is a unique key ? : Sql dba

637


What are the benefits of pl/sql packages?

638


Does sql full backup truncate logs?

638






What is clause in sql?

673


how to create a test table in your mysql server? : Sql dba

581


what is bcp? When is it used?

670


How do temporal tables work?

607


What is nvarchar in sql?

606


Which one is faster ienumerable or iqueryable?

569


Is left join and outer join same?

646


Can we enter data in a table in design view?

598


mention if it is possible to import data directly from t-sql commands without using sql server integration services? If yes, what are the commands? : Transact sql

668


What is difference between rank () row_number () and dense_rank () in sql?

685