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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
JiriS
Helper I
Helper I

Create row for each week in daterange

Hi,

 

I want to create a report. I have dataset and by using DAX I change the dataset to the format I need.

Than it looks like that: 

NamePersonal numberDate fromDate toDepartmentType
Peter12141212.08.202024.09.2020

D1

X
George12151624.12.201901.02.2020D2X
George12151601.03.202005.08.2020D1Y

 

By using DAX I need to create this table:

NamePersonal numberDepartmentTypeWeekYear
Peter121412D1X332020
Peter121412D1X342020
Peter121412D1X352020
Peter121412D1X362020
Peter121412D1X372020
....     

It means that I want to have for each week between daterange (from-to) one row.

How can I do that?

 

Thank you,

George

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@JiriS, I've done it for Dates in this file.

https://www.dropbox.com/s/bqbei7b8qbq5xez/leavebetweendates.pbix?dl=0

If you can week and year on your calendar. You should be able to group in the year of the week

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@JiriS, I've done it for Dates in this file.

https://www.dropbox.com/s/bqbei7b8qbq5xez/leavebetweendates.pbix?dl=0

If you can week and year on your calendar. You should be able to group in the year of the week

Thank you for your solution.

George

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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