# Find first day or last day of the week

**URL:** <https://community.dremio.com/t/find-first-day-or-last-day-of-the-week/5549>\
**Category:** Uncategorized\
**Created:** [May 12, 2020, 6:19pm UTC](https://community.dremio.com/t/find-first-day-or-last-day-of-the-week/5549 "2020-05-12T18:19:31Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![rajupillai](https://avatars.discourse-cdn.com/v4/letter/r/edb3f5/32.png) [@rajupillai](https://community.dremio.com/u/rajupillai)\
**Post date:** [May 12, 2020, 6:19pm UTC](https://community.dremio.com/t/find-first-day-or-last-day-of-the-week/5549/1 "2020-05-12T18:19:31Z")

</div>

How do I get the first day and last day of the week for a given date field ?

I am so used to running :

select date\_add(‘2020-02-24’,5 - pmod(datediff(‘2020-02-24’,‘1900-01-01’),7));

It doesn’t work in Dremio. There is no example on the documentation either. Can you help ?
