title: PHP MySQL select all data from monday to friday or select all data from weekdays of last week
body: <p>I am new to mysql and I was wondering how to select 
  data from monday to friday of last week? Assuming that
  today is monday. Here's what I tried so far but it returned an empty result:</p>
  
  <pre><code>SELECT * , SUM(time) AS total_project_hours
  FROM task
  WHERE DATE_SUB(NOW(), INTERVAL 1 WEEK ) BETWEEN 0 AND 4 AND deleted='n'
  GROUP BY project_id
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/ttUyL.jpg" alt="enter image description here"></p>