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

Get inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.

Reply
Gusd8
Helper I
Helper I

Take field and append to bottom of table

Thank you for looking. I am not even sure how to text describe what I want to do. Imagine you own three houses and you have listed their values.

CityStateValue
MinneapolisMN180,000
Saint PaulMN190,000
MadisonWI210,000

 

So the sum or the value of homes is 580,000. You expect the houses to increase 5% in value in the coming 5 years. So you add a column and multiple Value by .05

CityStateValueProfit
MinneapolisMN180,0009,000
Saint PaulMN190,0009,500
MadisonWI210,00010,500

 

So the reporting goal is to have a matrix table that has state as the main Group...and then to be able to expand and see city value and profit value...so the data would look like this...

CityStateValue
MinneapolisMN180,000
Saint PaulMN190,000
MadisonWI210,000
ProfitMN18,500
ProfitWI10,500

 

Right now I I having a brain cramp, I have no idea on how I would bring the profit column down and append to the City column.

 

Please don't judge the example, it is not a real world example, it meant to show what I have been asked to do with a different data set (and what they are asking actually does make sense). Any ideas on how to do this efficiently would be greatly appreciated. The only thing I can think of right now is build a duplicate data set, add the calculated column, change the name of all of the city values to Profit and then append the second table to the first. It just feels like a lot of work and processing. Thank you again for looking. All ideas are welcome.

2 REPLIES 2
v-stephen-msft
Community Support
Community Support

Hi @Gusd8 ,

 

It's easy to append query in Power Query, please refer to

Append queries - Power Query | Microsoft Learn

Here's an example about appending in Power Query. I created Table (2) and appended Table (2) to Table.

vstephenmsft_0-1695631033487.png

vstephenmsft_1-1695631063975.png

 

If you don't want to append in Power Query, you can try calculated tables using DAX in Power BI Desktop.

Table 2 = UNION(SELECTCOLUMNS(ADDCOLUMNS('Table (3)',"Profit",[Value]*0.5),"City","Profit","State",[State],"Value",[Profit]),'Table (3)')

vstephenmsft_2-1695631451393.pngvstephenmsft_3-1695631457459.png

 

 

Best Regards,

Stephen Tao

 

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

Gusd8
Helper I
Helper I

I should also say that the third table could easily look like this...

CityStateValue
MinneapolisMN180,000
Saint PaulMN190,000
MadisonWI210,000
ProfitMN9,000
ProfitMN9,500
ProfitWI10,500

It would get grouped in the Matrix 🙂 Thank You

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

Top Kudoed Authors