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!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hello,
I have many tables in power query that I don't want to merge. I'd like thanks to DAX to do somethong like this :
If ('Tab1'[Type] = "Pipe")
then return 'Tab1'[thickness] * Tab2[surface] where 'Tab1'[Size] = 'Tab2'[Size]
else return 'Tab1'[thickness]
| Tab1 | ||
| Type | Size | thickness |
| Pipe | 7 | 30 |
| Valve | 2 | 20 |
| Pipe | 6 | 20 |
| Valve | 5 | 20 |
| Tab2 | |
| Size | new_size |
| 2 | 4 |
| 5 | 9 |
| 6 | 8 |
| 7 | 1 |
I don't know how to manage the "where 'Tab1'[Size] = 'Tab2'[Size]" part of it. Any idea ?
Thanks a lot !
Solved! Go to Solution.
Hi @Anonymous ,
Assuming that you have a relationship between Data Table and Size Table.
Using MEASURES
USING A CALCULATED COLUMN
Regards,
Harsh Nathani
Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)
Hi @Anonymous ,
Assuming that you have a relationship between Data Table and Size Table.
Using MEASURES
USING A CALCULATED COLUMN
Regards,
Harsh Nathani
Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)
@Anonymous ,
Hahaha..
Loved the spoiler.
Happy to help.
Regards,
Harsh Nathani
Not done on purpose. 😅
Hi @Anonymous
Can you provide an example based on the data, with the expected result?
Please mark the question solved when done and consider giving kudos if posts are helpful.
Contact me privately for support with any larger-scale BI needs, tutoring, etc.
Cheers
Hi,
Thanks for answering me. I have the 2 below tables :
T_Data:
T_Data
T_size:
T_size
I try to do some thing like this : mesure = if('T_Data'[Type] = "Pipe",if('T_Data'[DN] = 'T_size'[DN],SUM('T_Data'[Thickness]) * SUM('T_size'[Surface pipe (m2/ml)]),0),0).
I'd like to have a meusure where I have sum of all pipe thickness by surface : 'T_Data'[Thickness] * 'T_size'[Surface pipe (m2/ml)] where type = pipe for each DN corresponding surface.
Is that clear or do you need more details ?
Thanks !
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 14 | |
| 5 | |
| 4 | |
| 3 | |
| 2 |
| User | Count |
|---|---|
| 25 | |
| 10 | |
| 10 | |
| 6 | |
| 6 |