title: I have data at Store_Id, Date level and have to mark whether that store was visited or not week-wise using SQL
body: <p>I have Data at Store_Id, Date level as represented below:</p>
  <div class="s-table-container">
  <table class="s-table">
  <thead>
  <tr>
  <th>Store_Id</th>
  <th>Date</th>
  </tr>
  </thead>
  <tbody>
  <tr>
  <td>1</td>
  <td>01-01-2020</td>
  </tr>
  <tr>
  <td>2</td>
  <td>01-01-2020</td>
  </tr>
  <tr>
  <td>3</td>
  <td>01-01-2020</td>
  </tr>
  <tr>
  <td>1</td>
  <td>07-01-2020</td>
  </tr>
  <tr>
  <td>3</td>
  <td>07-01-2020</td>
  </tr>
  <tr>
  <td>1</td>
  <td>13-01-2020</td>
  </tr>
  <tr>
  <td>2</td>
  <td>13-01-2020</td>
  </tr>
  </tbody>
  </table>
  </div>
  <p>I want to convert the above table at Store_Id, week level and mark whether that store was visited or not.
  Somewhat like represented below</p>
  <div class="s-table-container">
  <table class="s-table">
  <thead>
  <tr>
  <th>Store_Id</th>
  <th>Week</th>
  <th>Visit</th>
  </tr>
  </thead>
  <tbody>
  <tr>
  <td>1</td>
  <td>1</td>
  <td>YES</td>
  </tr>
  <tr>
  <td>2</td>
  <td>1</td>
  <td>YES</td>
  </tr>
  <tr>
  <td>3</td>
  <td>1</td>
  <td>YES</td>
  </tr>
  <tr>
  <td>1</td>
  <td>2</td>
  <td>YES</td>
  </tr>
  <tr>
  <td>2</td>
  <td>2</td>
  <td>NO</td>
  </tr>
  <tr>
  <td>3</td>
  <td>2</td>
  <td>YES</td>
  </tr>
  <tr>
  <td>1</td>
  <td>3</td>
  <td>YES</td>
  </tr>
  <tr>
  <td>2</td>
  <td>3</td>
  <td>YES</td>
  </tr>
  <tr>
  <td>3</td>
  <td>3</td>
  <td>NO</td>
  </tr>
  </tbody>
  </table>
  </div>
  <p>Can someone suggest to me a way to do that?</p>