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
JoanElGran1899
Frequent Visitor

Sum Total Data Diff with one min(data created) and other max(data) about diferent tables

Hi everyone,
May I ask for some help with an issue me and my team are facing.

JoanElGran1899_0-1637159580019.png
We are trying to sum the time our team spent doing invoices. So we are taking from 'Dim Invoice' (table) the doc num, created by and the data created and from another table the time about the last line they done.
But the sum as you can see is not correct... The total metric is doing the max diferent, not the sum of the time.
Now i'll show you the diferent metrics and what i tried.

JoanElGran1899_1-1637160683748.png

JoanElGran1899_2-1637160714388.png

JoanElGran1899_3-1637160734190.png

Anyone know where the problem could come from?

Many thanks in advance for your help,


Joan


 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@JoanElGran1899 , Try like

Sumx(addcolumns(summarize( 'Dim Invoice, 'Dim Invoice[Document no], 'Dim Invoice'[Created by]) , "_1", [Date diff invoice minute] )  , [_1] )

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@JoanElGran1899 , Try like

Sumx(addcolumns(summarize( 'Dim Invoice, 'Dim Invoice[Document no], 'Dim Invoice'[Created by]) , "_1", [Date diff invoice minute] )  , [_1] )

Yess it works! By the way I want to ask you one more question, 
I need only to sum the time in the same day of the 'Data created'

JoanElGran1899_0-1637229718055.png
For exemple the last line i don't want to sum it.

Thank you

 

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.