Advertisement
Guest User

Untitled

a guest
Oct 21st, 2019
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.47 KB | None | 0 0
  1. select r.resort_id,
  2. r.resort_name,
  3. r.resort_street_address,
  4. r.resort_pcode,
  5. t.town_name,
  6. t.town_state,
  7. b.booking_charge AS totalbookingcharge
  8. from resort r
  9. join booking b on r.resort_id = b.resort_id
  10. join town t on t.town_id = r.town_id
  11. where booking_charge>(select avg(booking_charge) from booking)
  12. GROUP BY
  13. r.resort_id,r.resort_name,r.resort_street_address,r.resort_pcode,t.town_name,t.town_state,b.booking_charge;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement