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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

Add dynamic rows for each day

How to add dynamic rows for each day with the processor name as Tom, activity as Login, Quarter Hour as 7:15:00AM and activity duration as 25200 for the attached table? The same details should be added for each day of the month except weekends.

 

image.png

1 ACCEPTED SOLUTION
jdbuchanan71
Super User
Super User

Hello @Anonymous 

We can use PowerQuery and just do a couple transformations to get what you are looking for.

  • Reference the original table
  • Keep only 1 row for each unique date
  • Add the day name column and delete the weekend days
  • Use extract first 0 characters to clear all the data in the other columns
  • Fill in the Tom data
  • Append on the original table

I have saved an excel file example with the source data and the output table here: https://www.dropbox.com/s/y7109sh0ur9218x/AddTomRows.xlsx?dl=0

Original dataOriginal dataTom + original dataTom + original data

View solution in original post

4 REPLIES 4
jdbuchanan71
Super User
Super User

Hello @Anonymous 

We can use PowerQuery and just do a couple transformations to get what you are looking for.

  • Reference the original table
  • Keep only 1 row for each unique date
  • Add the day name column and delete the weekend days
  • Use extract first 0 characters to clear all the data in the other columns
  • Fill in the Tom data
  • Append on the original table

I have saved an excel file example with the source data and the output table here: https://www.dropbox.com/s/y7109sh0ur9218x/AddTomRows.xlsx?dl=0

Original dataOriginal dataTom + original dataTom + original data

v-yuta-msft
Community Support
Community Support

@Anonymous ,

 

No, power query doesn't suppot adding specific rows, you can only append multiple tables in power query. In your senario, I would suggest you to export the data to database and insert rows using SQL statement like INSERT INTO TABLE VALUES(...).

 

Community Support Team _ Jimmy Tao

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

Anonymous
Not applicable

Would this logic work? @v-yuta-msft 

 

image.png

@Anonymous ,

 

This is DAX function, not the power query code. The dax code you provided can only generate a temporary table in the report view level. So if you don't need to add rows in the raw table, you can use DAX fucntion.

 

Community Support Team _ Jimmy Tao

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

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

Top Kudoed Authors