The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi All,
This is driving me crazy. I reffered to this post by @Greg_Deckler. Created YTD measure for Project Profit column present in Loss Factor table. Created 2 separate measures Profit and Loss with below calculation:
Please try
Profit = CALCULATE(sum([Project Profit]) ,[Project Profit] > 0) Loss = CALCULATE(sum([Project Profit]) ,[Project Profit] < 0) OR Profit = CALCULATE(([Project Profit]) ,[Project Profit] > 0) Loss = CALCULATE(([Project Profit]) ,[Project Profit] < 0)
Appreciate your Kudos. In case, this is the solution you are looking for, mark it as the Solution. In case it does not help, please provide additional information and mark me with @
Thanks.
Hi @amitchandak sorry but you cannot use true/false condition inside calculate. Also we can not sum measure explicitly. The below dax by @TomMartens was quite close but still not giving the expected result.
MeasureProfitFinal = CALCULATE( SUMX( ADDCOLUMNS( SUMMARIZE('AllData' ,'AllData'[Client] ,'AllData'[Date].[Month] ,'AllData'[Retainer] ) ,"This",[MeasureProfit]) ,[This]) )
Please help me as this is bit urgent and not able to proceed further. When i export the data to the excel i get the correct result but not in Total row in table visual.
Ok, profit is a calculated measure
try this, something like
Sales GT 0 = CALCULATE(sum(Sales[Sales Amount]),filter(sales,Sales[Current Sales]>0)) or Sales GT 0 = CALCULATE((Sales[Sales Amount]),filter(sales,Sales[Current Sales]>0))
Hi @amitchandak please refer to my situation below:
I have column project profit in my table Loss Factor. I have created measure to get YTD values for Project Profit as below:
@Ashish_Mathur can you please assist me as i have seen you have answered similar posts.
Hi,
I am not clear with your question. Share some data, explain the question and show the expected result.
Hi All,
Thanks for all your help and time. While looking for solution, i came across this post which helped me in getting the expected result. So on top of the existing Profit and Loss measures which i made as intermediate, i created another 2 measures as shown below and got the desired result.
User | Count |
---|---|
26 | |
10 | |
8 | |
6 | |
5 |
User | Count |
---|---|
33 | |
13 | |
12 | |
9 | |
7 |