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

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

Reply

need help to create table

Hi all,

          I have two tables using them I want to get a new table. Please let me know how can I do this in Power BI. Thanks in adv

 

Herndon_powerbi_0-1625945760758.png

 

2 ACCEPTED SOLUTIONS
Anonymous
Not applicable

Hi @Herndon_powerbi ,

 

I have done it in two ways, please check:

 

  • Use DAX:
NewTable using DAX = 
var _t1=SUMMARIZE('Table1',"subject","english","total_marks",SUM(Table1[english]))
var _t2=SUMMARIZE('Table1',"subject","maths","total_marks",SUM(Table1[maths]))
var _t3=SUMMARIZE('Table2',"subject","science","total_marks",SUM('Table2'[science]))
return UNION(_t1,_t2,_t3)

new table using DAX.PNG

 

 

  • In Power Query:

For Table1:  select english and maths column -->click "Unpivot columns"--> select Attribute column --> click "Groupby"

For Table2:  select science column -->click "Unpivot columns"--> select Attribute column --> click "Groupby"

transform tables.PNG

And then click "Append Queries as new " to create a new table like this:

append tables as a new table.PNG

 

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

View solution in original post

Thank you so much

View solution in original post

2 REPLIES 2

Thank you so much

Anonymous
Not applicable

Hi @Herndon_powerbi ,

 

I have done it in two ways, please check:

 

  • Use DAX:
NewTable using DAX = 
var _t1=SUMMARIZE('Table1',"subject","english","total_marks",SUM(Table1[english]))
var _t2=SUMMARIZE('Table1',"subject","maths","total_marks",SUM(Table1[maths]))
var _t3=SUMMARIZE('Table2',"subject","science","total_marks",SUM('Table2'[science]))
return UNION(_t1,_t2,_t3)

new table using DAX.PNG

 

 

  • In Power Query:

For Table1:  select english and maths column -->click "Unpivot columns"--> select Attribute column --> click "Groupby"

For Table2:  select science column -->click "Unpivot columns"--> select Attribute column --> click "Groupby"

transform tables.PNG

And then click "Append Queries as new " to create a new table like this:

append tables as a new table.PNG

 

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

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!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.

Top Solution Authors
Top Kudoed Authors