cancel
Showing results for
Search instead for
Did you mean:

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Frequent Visitor

## How to get the date of the next specific day of the week from a given date

Hi fellow members,

I need to solve th following issue:

From a given date I need to obtain the date of thursday of the following week.

 Input date Input day of week Result Result day of week 06/09/2021 monday 16/09/2021 thursday (next week) 08/10/2021 friday 14/10/2021 thursday (next week) 13/10/2021 wednesday 21/10/2021 thursday (next week) 18/10/2021 monday 28/10/2021 thursday (next week)

Thanks in advance

### @BA_Pete

1 ACCEPTED SOLUTION
Super User

Hi @renecernitz ,

Try this in a new custom column:

``Date.AddDays(Date.EndOfWeek([Input date]), 4)``

This gives me the following ouput:

Pete

Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!

3 REPLIES 3
Super User

Hi @renecernitz ,

Try this in a new custom column:

``Date.AddDays(Date.EndOfWeek([Input date]), 4)``

This gives me the following ouput:

Pete

Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!

Resident Rockstar

Suggest you specify the `firstDayOfTheWeek` argument as `Day.Monday`.

If I don't do that, your formula returns the next Wednesday.  Possibly due to my regional settings which have Sunday as the first day of the week.

Or, better yet, ask the OP when his week starts, and adjust accordingly.

Super User

Hi @ronrsnfld ,

Thanks for the suggestion.

If the necessary correction was more difficult than changing one number then I might have done so.

Pete

Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!

## Helpful resources

Announcements

#### Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

#### Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

#### The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors