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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Issue With total using Divid Formula

Hi

 

Trying to find the solutions everywhere but can't find anything so far so if you can help me on that it will be much appreciated ...

I have 3 Messures 

1/ Total Ctr Ext and PI => SumX(Activites,Activites[Ctrl_Ext])+SUmx(activites,Activites[Ctrl_PI

2/ Total LIv => SUMX(Activites,Activites[Livr-Pose

3/ JOT_Nbtec.Ctrl => SUMX(JOT_Date_Tec,JOT_Date_Tec[JT_tableJot])-[Tot J.Ctrl_NonProd

Last piece is also a messure which is just a SUM

 

With this 3 messure I'm trying to calculate a ratio with a formula Divide 

JotFinal => (divide([Tot Ctrl_ExtPI],[Tot Ctrl_ExtPI]+[Tot Liv]))*[JOT_Nbtec.Ctrl
 
When i look at the line everything is fine but when the total doesn't match at all ...
I tried to implement the formula HASONEFILTER but so far i did not succed ...
 
Can anyone help me on that ?
Thanks
4 REPLIES 4
selimovd
Super User
Super User

Hey @Anonymous ,

 

the function SUMX iterates through every row, is then calculating the expression in the second parameter per row and at the end summing up the result of the values per row.

Take a look at the following function:

Ctr Ext=
SUMX(
    Activites,
    Activites[Ctrl_Ext]
)

 

You don't do any operation on a row level in the second parameter. So don't use SUMX, just use SUM. It's faster and easier to read:

Total Ctr Ext and PI = SUM( Activites[Ctrl_Ext] ) + SUM( Activites[Ctrl_PI] )

 

Then you write "When I look at the line everything is fine but when the total doesn't match at all".

I don't know how the result should look like. What do you expect? What do you want to calculate? And what does the result of your measure look like?

 

Give a little more information, then it's easier to help you.

 

If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
 
Best regards
Denis
 
Anonymous
Not applicable

Thanks for your reply when i said that the total dosen't look here is what is have 

If you do the sum you'll see that the total 42.63 doesn't tied back

However the figure by line is the figure that i expect

Romain1768_0-1620729224753.png

 

Anonymous
Not applicable

Hey @selimovd 

 

Sorry to bother but still stuck with this issues can you help ? 

Or recommande another solution ?

 

Thanks

Romain

Hey @Anonymous ,

 

in this community always mark a user by typing an "@" and the user name. Otherwise I don't get a notice that you replied 😉

 

Can you send me a screenshot of the underlying data?

And also, please let me know which measure that is including the formula.

 

Best regards

Denis

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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