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

View all the Fabric Data Days sessions on demand. View schedule

Reply
Anonymous
Not applicable

Handling Granularity Based on Percent to Total Instead of Equal Distribution

Instead of just disaggregating the budget amount evenly across invoices like in Column I; using DAX Power BI, how can I calculate the percent the invoice is to the total net amount for invoices charged to that specific lawsuit and then divide the budget based upon that percent (like in Column K)? I've attached a screenshot, and the formula would be a variation of the formula below.

 

Goal =
[Amount paid to date for law suit]
    / CALCULATE (
        COUNTROWS ( TableName ),
        ALLEXCEPT ( TableName, TableName[Lawsuitkey] )
    )powerbi example 2.PNG
2 REPLIES 2
Stachu
Community Champion
Community Champion

assuming lawsuit is the same as project id this calculated column should work

Column = 
VAR __ProjectKey = 'Table'[Project Key]
VAR __InvoiceHeaderKey = 'Table'[Invoice Header Key]
VAR __TotalPerProject = CALCULATE(SUM('Table'[Budgeted Amount]), FILTER(ALL('Table'), 'Table'[Project Key] = __ProjectKey))
RETURN
__TotalPerProject*'Table'[Invoice Percent Of Total Invoices]


Did I answer your question? Mark my post as a solution!
Thank you for the kudos 🙂

Anonymous
Not applicable

@Stachu I guess the first question should have been how do I get 

'Table'[Invoice Percent Of Total Invoices]

This column is the Invoice Percent of Total Invoices grouped by Consulting Company Key 

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.