Answered You can hire a professional tutor to get the answer.

QUESTION

an someone please check my SQL query? It is nearly finished but i can't find the small errors.. i know i have an error by the GROUP BY clause and

an someone please check my SQL query? It is nearly finished but i can't find the small errors.. i know i have an error by the GROUP BY clause and maybe FROM, but nothing i change works. Help..?

/* Used with a movie rental database: 

WITH t2 AS

(SELECT category, rental_duration,

NTILE(4) OVER (ORDER BY rental_duration) standard_quartile

FROM

(SELECT c.name category, f.rental_duration

FROM film f

JOIN film_category fc

ON f.film_id = fc.film_id

JOIN category c

ON fc.category_id =c.category_id)t1

WHERE category IN ('Animation', 'Children', 'Classics', 'Comedy', 'Family', 'Music'))

group by 1,2

ORDER BY 1,2;

Show more
LEARN MORE EFFECTIVELY AND GET BETTER GRADES!
Ask a Question