Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply

Populate dates between SoW and EoW

Hello,

 

I have a standard fiscal calender which I liked to populate with our companies bespoke FY details which are held within another Power Query:

ShelleyBaynton_1-1675872285174.png 

 

ShelleyBaynton_0-1675872073400.png

I've tried the following:-

  • Created a relationship between SoW and Week Commencing
  • Used Related function to pull through
  • Merge the power queries to create new data set

 

Neither options returned a workable solution 😥

 

Any assistance would be warmly welcomed 

1 ACCEPTED SOLUTION
AnastasiaS
Resolver I
Resolver I

Hi  @Shelley-Baynton 

 

You could try to add to your table containing SoW and EoW, a column that will contain the dates between the start and end : 

In power query

1. go to add column -> Custom column

AnastasiaS_0-1675876379800.png

 

Type the following code:

={Number.From([Start])..Number.From([End])}

where you replace [start] and [end] with the right col names

 

This will add you a new column. Then click on the icon on the right and select "Expand to new rows"

AnastasiaS_2-1675876488805.png

This will add you a row per date; you'll only have to transform the type to date as it will be numeric:

AnastasiaS_3-1675876653924.png

 

Then, you could merge your date table with this table, based on the newly created column. You'll have matching values as both contain daily rows.

After merge, you can chose to keep only the FY detail column.

 

Could you try that and tell if this corresponds to your need? Don't hesitate if smth is not clear.

 

Regards,

View solution in original post

1 REPLY 1
AnastasiaS
Resolver I
Resolver I

Hi  @Shelley-Baynton 

 

You could try to add to your table containing SoW and EoW, a column that will contain the dates between the start and end : 

In power query

1. go to add column -> Custom column

AnastasiaS_0-1675876379800.png

 

Type the following code:

={Number.From([Start])..Number.From([End])}

where you replace [start] and [end] with the right col names

 

This will add you a new column. Then click on the icon on the right and select "Expand to new rows"

AnastasiaS_2-1675876488805.png

This will add you a row per date; you'll only have to transform the type to date as it will be numeric:

AnastasiaS_3-1675876653924.png

 

Then, you could merge your date table with this table, based on the newly created column. You'll have matching values as both contain daily rows.

After merge, you can chose to keep only the FY detail column.

 

Could you try that and tell if this corresponds to your need? Don't hesitate if smth is not clear.

 

Regards,

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors