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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
icturion
Resolver II
Resolver II

Power Query to DAX

I have the following Power Query that works fine in a normal table.Power Query.JPG

But now i want to use the same formule in a DAX table but thats not possible for so far i know.

So the question is can somebody help me by writing the formule in DAX?

 

9 REPLIES 9
amitchandak
Super User
Super User

@icturion , Try like

Summarize(
union(
selectcolumns(Table, "Date", Table[datein], "Work1", [Work1], "Work2", 0, , "Work3", 0),
selectcolumns(Table, "Date", Table[dateout], "Work1", 0, "Work2", [Work2] , "Work3", 0),
selectcolumns(Table, "Date", Table[datecheck], "Work1", 0, "Work2", 0 , "Work3", [Work3])
), [Date], "Work1", sum([Work1]), "Work2", sum([Work2]), "Work3", sum([Work3]), "Total", sum([Work1])+sum([Work2])+sum([Work3]))

 

 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

@amitchandak 

Where do i need to place the formula?

 

Within tabel1? As a Calculated column or measure?

If i place it in a measure i get the following error:
error.JPG

Can't find table with column [work1]

smpa01
Community Champion
Community Champion

@icturion Where do i need to place the formula?

 

Capture.PNG

Did I answer your question? Mark my post as a solution!
Proud to be a Super User!
My custom visualization projects
Plotting Live Sound: Viz1
Beautiful News:Viz1, Viz2, Viz3
Visual Capitalist: Working Hrs

@icturion , that is new table 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

@amitchandak If i place it in a new table is still get the same error.

icturion_0-1614706936139.png

Unable to identify the column [work1] in the table

@amitchandak 

 

From this table 'tabel1':
Table1.JPG

 

I want to create a new table using DAX that shoud have this as a result:
correct.JPG

 

if i use your formula to create a new table i get the following:
get.JPG
Are I am doing something wrong?

Hi @icturion ,

 

Please provide a sample .pbix file or sample data that can be copied.

 

Best regards,
Lionel Chen

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

amitchandak
Super User
Super User

@icturion ,Can you share sample data and sample output in table format?

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

@amitchandak 
Sample data tabel1
Table1.JPG

Result tabel2:
tabel2.JPG

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.