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

Microsoft is giving away 50,000 FREE Microsoft Certification exam vouchers. Get Fabric certified for FREE! Learn more

Reply
Seth4040
Regular Visitor

AP Data SUM based on multiple variables

I need some help being able to SUM this data Account Payable raw data in which has Invoice #, Inv Amount, GL Acct, Line Amount, Reviewer Group and OPS Center.  I always want to see how much in being invoiced per each OPS Center.  I have attached some documents to take a look at. I see because Different reviewer group that it is doubling the line amount when it should only be 86.72 of the 4896.31 invoice amount. 

 

Inv #Inv AmountGL AcctLine AmountReviewer GroupOPS Center
25022096760000024622.2351810.43.1204533.171218-INVCary/Raleigh
2502209676000004896.3151810.43.121886.721218-INVTriad
2502209676000004896.3151810.43.121886.721205-INVTriad

 

1 ACCEPTED SOLUTION
v-xuxinyi-msft
Community Support
Community Support

Hi @Seth4040 

 

Thanks for the reply from samratpbi .

 

Seth4040, not quite sure what your desired result is, I used the following measure to calculate the sum of the Line Amount of the two OPS Centers in the sample data.

 

 

Total Inv Amount = 
SUMX(
    SUMMARIZE(
        'Table',
        'Table'[OPS Center],
        "LineAmount", MAX('Table'[Line Amount])
    ),
    [LineAmount]
)

 

 

Output:

vxuxinyimsft_0-1738223236016.png

 

If you need further help, please feel free to let me know. It would be even better if you could give expected results based on example data. Please remove any sensitive data in advance.

 

Best Regards,
Yulia Xu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-xuxinyi-msft
Community Support
Community Support

Hi @Seth4040 

 

Thanks for the reply from samratpbi .

 

Seth4040, not quite sure what your desired result is, I used the following measure to calculate the sum of the Line Amount of the two OPS Centers in the sample data.

 

 

Total Inv Amount = 
SUMX(
    SUMMARIZE(
        'Table',
        'Table'[OPS Center],
        "LineAmount", MAX('Table'[Line Amount])
    ),
    [LineAmount]
)

 

 

Output:

vxuxinyimsft_0-1738223236016.png

 

If you need further help, please feel free to let me know. It would be even better if you could give expected results based on example data. Please remove any sensitive data in advance.

 

Best Regards,
Yulia Xu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

samratpbi
Super User
Super User

Hi, I can see your last 2 rows are same. Hence it is doubled. If duplicate rows are expected then you can take average instead of sum. 

If this helps to resolve your issue then please mark it as solution, thanks!

Helpful resources

Announcements
PBIApril_Carousel

Power BI Monthly Update - April 2025

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

Notebook Gallery Carousel1

NEW! Community Notebooks Gallery

Explore and share Fabric Notebooks to boost Power BI insights in the new community notebooks gallery.

April2025 Carousel

Fabric Community Update - April 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors