Starting December 3, join live sessions with database experts and the Microsoft product team to learn just how easy it is to get started
Learn moreGet certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now
Hi im trying to based on 2 conditions from different tables give a decided value or else 0.
Have tried to put in a custom column:
if([Besparelse] = 1 and (#"Kontoplan"[Mva Norge] =>0 then 0,25 else 0))
[Besparelse] = from primary table
Kontoplan = is the second table
Solved! Go to Solution.
@Da_clint , In the power query you have to merge tables before you can write some condition across table, AFter merge, they are in a single table.
In DAX you can bring the column back into your table
refer 4 ways to copy data from one table to another
https://www.youtube.com/watch?v=Wu1mWxR23jU
https://www.youtube.com/watch?v=czNHt7UXIe8
Hi @Da_clint ,
Here I create a sample to have a test.
Kontoplan:
Primary:
Custom column:
if [Besparelse] = 1 and
List.Sum(
let
_Customer = [Customer]
in
Table.SelectRows(Kontoplan, each [Customer] = _Customer)
[Mva Norge]) >= 0 then 0.25 else 0
Here I add this custom column into Primary table. Result is as below.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thank you Rico
I see that this probably also will work, but I solved it by bringing in the data to the same table & then use a IF && function in DAX
@Da_clint , In the power query you have to merge tables before you can write some condition across table, AFter merge, they are in a single table.
In DAX you can bring the column back into your table
refer 4 ways to copy data from one table to another
https://www.youtube.com/watch?v=Wu1mWxR23jU
https://www.youtube.com/watch?v=czNHt7UXIe8
Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.
User | Count |
---|---|
26 | |
20 | |
19 | |
14 | |
14 |
User | Count |
---|---|
44 | |
36 | |
24 | |
24 | |
22 |