Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
Hi,
Based on the following diagram,
I want to create the next calculated column, value, in the table INDICATOR based on two metrics and one variable:
value=(deliveries/planedDeliveries)*weight
metrics:
mDeliveries = sum(deliverie)
mPlanedDeliveries = sum(planedDeliverie)
I have done this but i'm not getting the correct values, so i created another two costum columns deliveries and planedDeliveries, to check what was causing the trouble:
deliveries = mDeliveries
planedDeliveries = mPlanedDeliveries
and i verified that the column planedDeliveries is giving diferent values from the expected in each line, i also tried to calculate:
planedDeliveries = CALCULATE( SUM (TASK[planedDeliverie]), FILTER (TASK, GE_TAREFAS[ID_Indicador] = EARLIER (INDICATOR[ID_Indicador] )))
but is giving me the same wrong values.
When i filter the metric planedDeliveries in the Dashboard it is giving correct values.
Can you someone tell me why i am not getting correct values in the costum column for the planedDeliveries ?
Thanks,
ROCO
Hi @Anonymous
You could create measures as below
sum_delivery = SUM(task[delivery]) sum_planned = SUM(task[planned delivery]) measure_value = ([sum_delivery]/[sum_planned])*SUM(indicator[weight])
Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @v-juanli-msft ,
Thanks for the answer, i already did those metrics, but the problem is that the metric:
SUM(task[planned delivery])
is giving me diferent values from the expect ones, when i calculate it in a custom column, i need to do this calculation in a custom column:
([sum_delivery]/[sum_planned])*SUM(indicator[weight])
because i need to do further calculation based on the values of this column.
It's strange because the sum(task[delivey]) is giving correct values, but the sum(task[planned delivey]) not, when calculated in the custom column.
Do you have any idea why this is happening?
I just noticed what the problem is, i want to filter the Calculated Column:
planned_Deliveries = SUM(task[planned delivery])
In the report by Task[date], and it's not filtering (this column comes from SSAS).
Is it possible to filter a Calculated Column from SSAS in Power BI?
Hi @Anonymous
When connect to SSAS with live connection, you could only create measure not columns, what you create in Power BI can't return back to SSAS.
Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@Anonymous you have to add these as measures, not columns.
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
@parry2k thanks for the reply, but as i said above i already tried with measures (metrics):
value=(deliveries/planedDeliveries)*weight
metrics (measures):
mDeliveries = sum(deliverie)
mPlanedDeliveries = sum(planedDeliverie)
but i'm not getting the correct values...
I have to get all the INDICATOR values in the column value to do other further calculations based on that column.
As i said the problem is with the measure mPlanedDeliveries = sum(planedDeliverie) that is not giving the correct values in each row of the INDICATOR table.
Do you know or have an idea why?
User | Count |
---|---|
128 | |
108 | |
100 | |
64 | |
62 |
User | Count |
---|---|
136 | |
113 | |
102 | |
71 | |
60 |