Welp Project Step 9

I would appreciate some feedback on the code I wrote below for the Welp project step 9 as I am not 100% sure this is the correct way.
Thanks!

SELECT * 
FROM places
LIMIT 3;
 
SELECT * 
FROM reviews
LIMIT 3;

SELECT name, price_point 
FROM places 
WHERE price_point LIKE "%$$";

SELECT p.name,p.average_rating, r.rating,r.review_date, r.note
FROM places p
INNER JOIN
reviews R
ON
p.id = r.place_id
ORDER BY average_rating DESC,rating DESC;

SELECT p.name AS No_Reviews
FROM places p
LEFT JOIN
reviews R
ON
p.id = r.place_id
WHERE r.place_id IS NULL;

SELECT r.username, COUNT(r.rating)
FROM 
reviews r
JOIN 
places p
WHERE r.rating < p.average_rating
GROUP BY r.username
ORDER BY COUNT(r.rating) DESC
LIMIT 10;


1 Like

Looks the same as the option I eventually used; there is some discussion of a few different interpretations of the same question at-

There are probably several others on the forums if you felt like searching for them.

I think your interpretation would be the right choice but you can always try looking at in a different way and writing a query for that if you want more practice.

1 Like