# Viewing records in the current week

**URL:** https://air.tableforums.com/t/viewing-records-in-the-current-week/449
**Category:** Show and Tell
**Created:** [March 23, 2023, 9:14pm UTC](https://air.tableforums.com/t/viewing-records-in-the-current-week/449 "2023-03-23T21:14:03Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Kuovonne](https://yyz1.discourse-cdn.com/flex029/user_avatar/air.tableforums.com/kuovonne/32/17_2.png) [@Kuovonne](https://air.tableforums.com/u/Kuovonne)
#### Post date: [March 23, 2023, 9:14pm UTC](https://air.tableforums.com/t/viewing-records-in-the-current-week/449/1 "2023-03-23T21:14:03Z")

</div>

Suppose you want to view all the records for the current week, based on a {Due Date} field. The {Due Date} could be any day of the week: Monday through Friday, and you want to see all the records within the current week, whether or not they are before or after the current day. For example, on Wednesday, you want to see records that were due back on Monday as well as records that won’t come due until Friday.

Airtable filters work well for showing dates before or after a given date, or within a specific interval of dates before or after the current date. However, Airtable filters don’t do well when the number of dates before/after the current date change.

One answer is to create a formula field that converts both the {Due Date} and TODAY() to the starting day of the week and compares them. You can then fitter on the result. In the screen shot below, there are two comparison fields, one that just checks if the record is due this week, another that gives a number indicating if the record is in the current week, next week, previous week, etc.

 ![image](https://canada1.discourse-cdn.com/flex029/uploads/tableforums/original/1X/bf64203720154e01f6c73de7bdc6b2753e0ad9cc.png)

Here is a formula that converts a date to the preceding Sunday.

```auto
DATEADD(
    {Due Date},
    WEEKDAY({Due Date}) * -1,
    "days"
)

```

The other formulas are easily derived from this one.

- To find the preceding Sunday for the current week, use TODAY() instead of {Due Date}
- To compare the two calculated dates, use DATETIME\_DIFF() or IS\_SAME().

---

<div class="post-metadata">

### Author: ![ScottWorld](https://yyz1.discourse-cdn.com/flex029/user_avatar/air.tableforums.com/scottworld/32/5_2.png) [@ScottWorld](https://air.tableforums.com/u/ScottWorld)
#### Post date: [March 24, 2023, 12:14am UTC](https://air.tableforums.com/t/viewing-records-in-the-current-week/449/2 "2023-03-24T00:14:54Z")

</div>

Love it! Great tip! 🤩 👏

---

<div class="post-metadata">

### Author: ![kmessmerized](https://yyz1.discourse-cdn.com/flex029/user_avatar/air.tableforums.com/kmessmerized/32/949_2.png) [@kmessmerized](https://air.tableforums.com/u/kmessmerized)
#### Post date: [March 28, 2023, 5:44pm UTC](https://air.tableforums.com/t/viewing-records-in-the-current-week/449/3 "2023-03-28T17:44:39Z")

</div>

Thanks so much for sharing!

JFYI for others: In attempting to do this without time zone and then using New\_York time zone, it kept outputting Saturday as the start of the week. I fixed it by going into the Formula Formatting and using the GMT/UTC time zone for all collaborators.

---

<div class="post-metadata">

### Author: ![Kuovonne](https://yyz1.discourse-cdn.com/flex029/user_avatar/air.tableforums.com/kuovonne/32/17_2.png) [@Kuovonne](https://air.tableforums.com/u/Kuovonne)
#### Post date: [March 28, 2023, 5:52pm UTC](https://air.tableforums.com/t/viewing-records-in-the-current-week/449/4 "2023-03-28T17:52:50Z")

</div>

> [@kmessmerized](#):
>
> In attempting to do this without time zone and then using New\_York time zone, it kept outputting Saturday as the start of the week.

Is you Date field a date-only field or does it include time as well? If your field includes a time as well as a date, I recommend using SET\_TIMEZONE() in the formula instead of using GMT/UTC timezone for all collaborators. Using the GMT/UTC timezone for all collaborators but actually putting in the local time can cause downstream problems.

```auto
WEEKDAY(SET_TIMEZONE({Due Date/Time}, 'America/New_York'))

```

You may also have to adjust the formula to parse the date without the time.

```auto
DATEADD(
    DATETIME_PARSE(
        DATESTR(SET_TIMEZONE({Due Date/Time}, "America/New_York")),
        "YYYY-MM-DD"
    ),
    WEEKDAY(SET_TIMEZONE({Due Date/Time}, "America/New_York")) * -1,
    "days"
)

```

---

<div class="post-metadata">

### Author: ![kmessmerized](https://yyz1.discourse-cdn.com/flex029/user_avatar/air.tableforums.com/kmessmerized/32/949_2.png) [@kmessmerized](https://air.tableforums.com/u/kmessmerized)
#### Post date: [March 28, 2023, 5:58pm UTC](https://air.tableforums.com/t/viewing-records-in-the-current-week/449/5 "2023-03-28T17:58:28Z")

</div>

> [@Kuovonne](#):
>
> Is you Date field a date-only field or does it include time as well?

No time, only dates weirdly enough. Not sure why mine is defaulting to Saturday, but I’ll do the set\_timezone workaround to avoid issues.

UPDATE: adding timezone worked. Now the dates are Sundays as desired. Thanks!
