Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code FABINSIDER for a $400 discount.
Register nowThe Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.
Hi,
I have a function which calculates the Profit/Loss for the category in sales. But the problem is when most of the Orders are in payout pending bucket, Net Profit is obviously high.
What I want is to exclude Payout Pending rows when calculating the Net Profit by category but it also affects my bar graph which is cumbersome.
Please help!
Thanks in advance.
Solved! Go to Solution.
Hi @ash757 ,
Based on the testing, try using the following DAX formula to calculate the profit exclude payout pending.
Net Profit =
CALCULATE(
SUM(Snapdeal[Payable]) - SUM(Snapdeal[Cost]),
FILTER(Snapdeal, Snapdeal[Bucket] <> "Payout Pending" && Snapdeal[Bucket] <> "Cancelled")
)
The result is shown below.
Best Regards,
Wisdom Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @ash757 ,
Based on the testing, try using the following DAX formula to calculate the profit exclude payout pending.
Net Profit =
CALCULATE(
SUM(Snapdeal[Payable]) - SUM(Snapdeal[Cost]),
FILTER(Snapdeal, Snapdeal[Bucket] <> "Payout Pending" && Snapdeal[Bucket] <> "Cancelled")
)
The result is shown below.
Best Regards,
Wisdom Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
This works exactly as I wanted, Thanks!
Also, Can you tell me What's the function of "&&" and how is it different from "&"?
Hi @ash757
Simply based on the information provided, I would create this measure:
CALCULATE ( [net profit], KEEPFILTERS ( 'table'[payout pending] = "no" ) )
Otherwise, please provicde a workable sample data (not an image), your expected result from that and the reasoning behind. https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...
Proud to be a Super User!
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Check out the February 2025 Power BI update to learn about new features.
If you love stickers, then you will definitely want to check out our Community Sticker Challenge!
User | Count |
---|---|
84 | |
69 | |
68 | |
39 | |
39 |