Resort that charges the highest in SQL

Question:

Resort that charges the highest

Write a query to display the name of the resort that charges the highest. Sort the output on the resort name. 

Resort that charges the highest

Code:

Main.sql

select r.resortname
from resort r join cabincost c
on c.resortid=r.resortid
where c.rate=(select max(rate) from cabincost)
order by 1;

Recommended:

Leave a Comment

Your email address will not be published. Required fields are marked *