<PLEASE USE THIS TEMPLATE TO HELP YOU CREATE A GREAT POST!>
<Below this line, add a link to the EXACT exercise that you are stuck at.>
SQL analyzing Business Metrics 11/12 part 2
<Below this line, in what way does your code behave incorrectly? Include ALL error messages.>
Error: near line 1: near “as”: syntax error
<In this course, it often helps to include a screenshot of your whole web browser – that lets everyone see what you see. If you wish to include a screenshot, add it below this line.>
<If you wish to copy/paste in your code, you can use this next section. This will allow others to copy/paste your code for testing – something that they won’t be able to do with just a screenshot.>
select name, round(1.0 * count(distinct order_id) /
count(distinct orders.delivered_to), 2) as reorder_rate
from order_items
join orders on
orders.id = order_items.order_id
group by 1
order by 2 desc;
Replace this line with your code.
<do not remove the three backticks above>