search
Log In
Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
Welcome to GATE CSE Doubts, where you can ask questions and receive answers from other members of the community.
0 votes
6 views
Consider the following relations concerning a driving
school. The primary key of each relation is in
boldface.
STUDENT(S_Name,Class_No,Th_Mark,Dr_Mark)

S_Name – student name, Th-Mark – Theory mark, Dr_Mark –
driving mark
STUDENT_DRIVING_TEACHER(S_Name,Dr_T_Name)
Dr_T_Name – driving teachers name
TEACHER_THEORY_CLASS(Class_No,Th_T_Name)
Th_T_Name – theory teachers name
TEACHER_VAHICLE(Dr_T_Name,License_No)
VEHICLE(License_No,Make,Model,Year)
A student takes one theory class as well as driving
lessons and at the end of the session receives marks
for theory and driving. A teacher may teach theory,
driving or both. Write the following queries in SQL.
a)Find the list of teachers who teach theory and give
driving lessons on all the vehicles.
b)Find the pairs of students satisfying the following
conditions.
They have the same theory mark and
They have different theory teachers and
They have the same driving mark and
They have different driving teachers.
c)Find the list of students who are taught neither
theory nor driving lessons by Rakesh (teacher).
d)Find the list of students who have better marks
than Aman in both theory and driving.
e)Find the list of students who have who have more
marks than average theory mark of class 8.
f)Find the list of teachers who can drive all the
vehicles.
in Databases 5 points 6 views

Please log in or register to answer this question.

...