Question: 2 0 - The statement below is erroneous because select dept name, dept _ id , avg ( salary ) from instructor group by dept

20- The statement below is erroneous because select dept name, dept_id, avg(salary) from instructor group by dept_name;
a) avg(salary) is invalid
b) group by clause is not valid in this query
c) misplaced group by clause
d) dept name should not be selected
e) dept id should not be selected
21- Which of the following creates a temporary relation for the query on which it is defined?
a) where
b) from
c) with
d) select
e) none of them
22- In the query below which one of the following is a temporary relation?
with max_budget (value) as (select max(budget) from department)
select budget from department, max_budget where department.budget = max_budget.value:
a) budget
b) department
c) value
d) select
e) max_budget
23- Which of the following is not an aggregate function?
a) avg
b) sum
c) with
d) min
e) max
24- The command "delete from r where P;"
a) deletes tuple(s)
b) deletes relation
c) deletes attribute
d) all of them
e) none of them
25- Which one of the following deletes all the entries but keeps the structure of the relation?
a) delete from r where P;
b) delete from instructor where dept name= 'Finance';
c) delete from instructor where salary between 13000 and 15000 ;
d) delete from instructor;
e) none of them
26-Find the keyword to update the instructor relation by "update instructor salary = salary *1.05;
a) where
b) set
c) in
d) select
e) write
27- The problem of ordering the update in multiple updates is avoided using
a) set
b) where
c) case
d) when
e) with
28-The condition allows a general predicate over the relations being joined.
a) with
b) using
c) set
d) on
e) where
29- The query below is equivalent to
select * from student join takes using(ID);
a) select from student inner join takes using(ID);
b) select from student outer join takes using(ID);
c) select from student left outer join takes using(ID);
d) select from student right outer join takes using(ID);
e) none of the above
 20- The statement below is erroneous because select dept name, dept_id,

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!