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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
CP4L21
New Member

Pivot and Group Rows of Many Dates into Columns

Hi,

I have rows that contain dates and I want to Pivot those rows into a colmns. However, I want those dates to be grouped when i pivot them. For example, I have sales data for a given month that is broken down by each day and each day's date has multiple transactions. I want to group the dates into 4 columns: 7 Days Sales, 14 Days worth of Sales, 21 Days worth of Sales and 30 Days. 

 

If i do the traditional Pivot of rows, i will get as many columns of dates as there are rows. How can i pivot rows into columns while groupoing these rows based on the above mentioned 4 groups? 

4 REPLIES 4
CP4L21
New Member

i cant reply because it keeps telling invalid HTML. any sugesstions how to work around it ?

AlB
Community Champion
Community Champion

@CP4L21 

There seems to be a problem over the last days. I've heard several people complaining about that HTML error message. It usually works fine.

Share a file (Excel for instance) with the tables in it.

You have to share the URL to the file hosted elsewhere: Dropbox, Onedrive... or just upload the file to a site like tinyupload.com (no sign-up required).

 

SU18_powerbi_badge

Please accept the solution when done and consider giving a thumbs up if posts are helpful. 

Contact me privately for support with any larger-scale BI needs, tutoring, etc.

 

Icey
Community Support
Community Support

Hi @CP4L21 ,

 

Please refer to this blog to provide some sample data and your expected result:

How to provide sample data in the Power BI Forum - Microsoft Power BI Community.

 

Please remove sensitive information.

 

 

Best Regards,

Icey

AlB
Community Champion
Community Champion

Hi @CP4L21 

Can you provide an example of the initial table? Make sure that the content can be copied (i.e. not on a picture)

 

SU18_powerbi_badge

Please accept the solution when done and consider giving a thumbs up if posts are helpful. 

Contact me privately for support with any larger-scale BI needs, tutoring, etc.

 

 

 

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Kudoed Authors