Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
hej
i got this sql scrip that i need to use in power bi, but i just cant get it to work in dax
UPDATE b SET
[Parent] = ISNULL
(
(
SELECT
MAX(a.[LedgerAccount])
FROM
[dbo].[DIM_LedgerAccounts] a
WHERE
a.[LedgerAccount] < b.[LedgerAccount]
AND a.[Indentation] = b.[Indentation] - 1
AND a.[IncomeBalanceType] = b.[IncomeBalanceType]
AND a.[Company] = b.[Company]
)
,b.[LedgerAccount]
)
FROM
[dbo].[DIM_LedgerAccounts] b
GO
can someone help me make a solution
Solved! Go to Solution.
@Anonymous,
Check the post below.
https://community.powerbi.com/t5/Desktop/This-Function/m-p/326489#M145679
@Anonymous,
Try using ISBLANK, MAXX and FILTER to add a calculated column.
https://community.powerbi.com/t5/Desktop/conditional-join/m-p/340423#M152404
Hej
so i made this dax from your input
but it doesnt return an error but just cells with no value
i made the column parent in d_ledger account to be equel = 1 because there never is a parent in this data.
@Anonymous,
Check the post below.
https://community.powerbi.com/t5/Desktop/This-Function/m-p/326489#M145679
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
110 | |
95 | |
76 | |
65 | |
51 |
User | Count |
---|---|
146 | |
109 | |
106 | |
88 | |
61 |