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

Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM. Register now.

Reply
Mirithu
Helper II
Helper II

Dynamically Add New Columns From Datasource Upon Refresh

Hi,

I am reading data from an Oracle database table that has a column for every day of the current month. At the start of day, a new column for the previous day is added to the table. As today is the 11th of August, the table looks like below:

 

ProductDAY01DAY02DAY03DAY04DAY05DAY06DAY07DAY08DAY09DAY10
Mangoes45125237872288453
Apples51467189055311009

 

At start of day tomorrow, a new column named DAY11 will be added to the table with respective values.

 

Now, I am importing this data into PBI Desktop and displaying it using a matrix visual in the same layout but with a custom total column that sums up all the values in each row as below:

 

ProductDAY01DAY02DAY03DAY04DAY05DAY06DAY07DAY08DAY09DAY10Total
Mangoes45125237872288453328
Apples51467189055311009335

 

I would like to have the matrix updated with every new column and corresponding total at the start of each day when refresh occurs. For example, when the new column DAY11 is introduced in the table, when I refresh my matrix, the column DAY11 will also be automatically included and its values added to the total in the Total column.

Is this possible?

1 ACCEPTED SOLUTION
samdthompson
Memorable Member
Memorable Member

Hello, you should unpivot the columns in power query before loading then use the DayNumber column in your column field on the matrix. Your Table will look something like:

 

Product, Day, Value

Mangoes, 01, 45

Mangoes, 02, 12

Mangoes, 03, 5

...

 

 

// if this is a solution please mark as such. Kudos always appreciated.

View solution in original post

2 REPLIES 2
samdthompson
Memorable Member
Memorable Member

Hello, you should unpivot the columns in power query before loading then use the DayNumber column in your column field on the matrix. Your Table will look something like:

 

Product, Day, Value

Mangoes, 01, 45

Mangoes, 02, 12

Mangoes, 03, 5

...

 

 

// if this is a solution please mark as such. Kudos always appreciated.

Thank you @samdthompson . The unpivoting in power query has worked perfectly!

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.