Below is my sample data:

[![enter image description here][1]][1]

I am trying to form a query where I can get records within a date range.

Date Range is start of the week to end of the week. For example I want all records that falls between July 10th - July 16 AND July 24 to July 30.

What I tried is having all the startweek in a `Set<Date> setOfStartWeek` and endWeek in `Set<Date> setOfendWeek`. Used below query :

    List<Record> recList = [Select Id,Name,StartDate from Record where StartDate >= :setOfStartWeek AND StartDate <= :setOfEndWeek];

Desired Result => return records between July 10th - July 16 i.e records 1,2 AND return records between July 24 to July 30 i.e record 5,6. 

It did not return any results. Is there a way to do this? Thanks!!


  [1]: https://i.sstatic.net/gmZQf.png