title: Get the number of the weekday from each date in a date list
body: <p><strong><a href="https://dbfiddle.uk/?rdbms=postgres_13&amp;fiddle=edcf0bc39497b87aada3b144403859c2" rel="nofollow noreferrer">DB-Fiddle</a></strong></p>
  <pre><code>CREATE TABLE dates (
      date_list DATE
  );
  
  INSERT INTO dates
  (date_list)
  VALUES 
  ('2020-01-29'),
  ('2020-01-30'),
  ('2020-01-31'),
  ('2020-02-01'),
  ('2020-02-02');
  </code></pre>
  <p><strong>Expected Results:</strong></p>
  <pre><code>  Weekday
      2
      3
      4
      5
      6
  </code></pre>
  <hr />
  <p>I want go get the number of the weekday for each date in the table dates. <br>
  Therefore, I tried to go with the solution from <a href="https://stackoverflow.com/questions/41181990/extract-day-of-week-from-date-field-in-postgresql-assuming-weeks-start-on-monday">this question</a> but could not make it work:</p>
  <pre><code>SELECT 
  EXTRACT(DOW FROM DATE d.date_list))
  FROM dates d
  </code></pre>
  <p>How do I need to modify the query to get the expected result?</p>