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

New column in new table based on values of other tables

Hello, I tried posting on here earlier but can't see it anymore. Say I have two tables, Table 1 and Table 2.

 

Table 1

ShopYearLine itemValue
Shop A2022current assets total307125
Shop B2020CA total current assets19076

 

Table 2

Line itemNew name
CA total current assetsTotal current assets
current assets totalTotal current assets

 

For context, I am using table 2 to rename the line items in table 1. How do I use DAX to make a new table, Table 3, that looks like:

 

ShopYearTotal current assets
Shop A2022307125
Shop B202019076
1 ACCEPTED SOLUTION
Mahesh0016
Super User
Super User

@a22  Power Bi Desktop > Go to Modeling tab > Click On New Table > Paste  this code.

Mahesh0016_0-1683119440875.png

Table C =
SELECTCOLUMNS (
    'Table A',
    "Shop", 'Table A'[Shop],
    "Year", 'Table A'[Year],
    "Total current assets", 'Table A'[Value]
)

View solution in original post

1 REPLY 1
Mahesh0016
Super User
Super User

@a22  Power Bi Desktop > Go to Modeling tab > Click On New Table > Paste  this code.

Mahesh0016_0-1683119440875.png

Table C =
SELECTCOLUMNS (
    'Table A',
    "Shop", 'Table A'[Shop],
    "Year", 'Table A'[Year],
    "Total current assets", 'Table A'[Value]
)

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.

Feb2025 NL Carousel

Fabric Community Update - February 2025

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