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
jklunk
Frequent Visitor

Adding rows to group by weeks

I'm creating a report pulling data from Salesforce, and I'm trying to add rows that will group data by each week. These obviously need to update each week the report is run. I created a field from the data that pulls the respective Monday of each week, but need to determine how to autoinsert the row at each change in week and add the words "Week of" in front of the date. I feel like there should be an easy way to do this and I'm just missing it? I've attached a screen shot of how the list current looks in Excel for reference. My raw data looks identical to the screen shot without the grey "Week of" separator.

 

Any help is greatly appreciated.

 

Thanks,

JarrodBid List.gif 

1 ACCEPTED SOLUTION

Hi @jklunk ,

 

You can use the Matrix chart and place the date column and the weekly start date column in the rows of the chart.

Again,please refer to the pbix.

 

Best Regards,

Liang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

6 REPLIES 6
V-lianl-msft
Community Support
Community Support

Hi @jklunk,
 
Based on your description, you want the data in each row to mark the start date of each week and add the "week of" field.
You can use DAX to create a calculated column:
 
Column = "Week of "&(Sheet1[date]-WEEKDAY(Sheet1[date],2)+1)

 

You can refer to the pbix.

 

Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

 

I'm actually trying to add a row showing "Week of [Month] [Day]" above each group of dates that falls within that week starting on Monday of each week. I'm working on creating it with a macro in Excel but I'd prefer to run it all through Power BI if possible.

 

Jarrod

Hi @jklunk ,

 

Unfortunately, according to the chart I know, there is no chart that fully meets your needs in power bi.

Or is this matrix chart the result you want?

test_matrix.PNG

 

Best Regards,

Liang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

This matrix could possibly work, if I could get the details showing to the right (no need for count or sum). How did you create that matrix?

Hi @jklunk ,

 

You can use the Matrix chart and place the date column and the weekly start date column in the rows of the chart.

Again,please refer to the pbix.

 

Best Regards,

Liang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Liang,

 

This is excellent. One issue I'm having is that it it is consolidating anything with the same due date into one line so I'm losing dating. I'm new to Power BI, so I'm guessing there is an easy way to change this to show all even if Bid Due Date is the same?

 

Thanks,

Jarrod

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.