title: Window lag sqlzoo.net #7
body: <p>The query shown includes a JOIN t the world table so we can access the total population of each country and calculate infection rates (in cases per 100,000).</p>
  <p>Show the infect rate ranking for each country. Only include countries with a population of at least 10 million.</p>
  <p>Ans.</p>
  <pre><code>SELECT world.name,
         ROUND(100000*confirmed/population,00) as rd,
         rank() over (order by rd)
  FROM covid 
     JOIN world ON covid.name=world.name
  WHERE whn = '2020-04-20' 
    AND population &gt; 10000000
  ORDER BY population DESC
  </code></pre>
  <p>The above code is my solution, but still, I am getting the wrong answer. Does anyone know the correct solution?</p>