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!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Hi All,
I have the 2 tables shown below.
I need a DAX measure to calculate the balance, within the GiftSplit Table. (Balance = Pledge - PledgePayments)
I calculate:
SUMPledgeGiftSplit = calculate(SUM(RE_GiftSplit[amount]),RE_Gift[type]="Pledge")
SUMPledgePaymentGiftSplit = calculate(SUM(RE_GiftSplit[amount]),RE_Gift[type]="PledgePayment")
It doesn't work because GiftSplit[gift_id]=121 to 125 and the payments are on PledgePayment for which Gift[ linkedgift_id] 12=Gift[id] 12.
I tried :
PledgePaymentsGiftSplit =
VAR IDNO = SELECTEDVALUE(Gift[id])
RETURN
SUMX(FILTER(ALL(Gift),Gift[linkedgift_Id] = IDNO), GiftSplit[amount])
And I get this message : A single value for column 'amount' in table 'GiftSplit' cannot be determined.
I tried related and it doesn't work.
What am I doing Wrong? Thank You!
Solved! Go to Solution.
Thank you very much for the answer @amitchandak The requirements have been changed. Good Day.
@AH2022 , the first one is correct the second one need to me
calculate(SUM(RE_GiftSplit[amount]),filter( allselected(RE_Gift), RE_Gift[RE_Gift] =max(RE_Gift[Gift_id]) && [ID] <= Max([ID]) && RE_Gift[type]="PledgePayment") )
Thank you very much for the answer @amitchandak The requirements have been changed. Good Day.