As 7
As 7
b.
Code:
c.
Code:
ii. Insert five rows into sailor, boat and reserve tables.
Ans.
INSERT INTO sailor
Code:
Code:
SELECT * FROM reserve;
3
Output:
Output:
3
v. Find the name of boat reserve by sailor name.
Ans.
Code:
Output:
vi. Find the name of sailor who have reserved at least one
boat.
Ans.
Code:
Output:
vii. Find the name of sailor who have reserved different boat
on same date
Ans.
Code:
Output:
viii. Find the name of sailor who have reserved a red boat or
green boat
Ans.
Code:
Output:
Ans.
Code:
5
Output:
Output:
xi. Find the average age of sailor for each rating levels.
Ans.
Code:
Output: