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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
PSRai
Helper III
Helper III

Total of a Measure

Hi 

 

Happy New Year

 

I have a measure that is correctly working out row by row data, When I use the same measure as a tile the total is incorrect

 

 

read_at (bins) Hours       Energy Used

27/11/2019 07:00             9.68

27/11/2019 08:00             17.41

27/11/2019 09:00             18.25

27/11/2019 10:00             17.38

27/11/2019 11:00             18.49

27/11/2019 12:00             20.49

27/11/2019 13:00             19.5

27/11/2019 14:00             17.95

27/11/2019 15:00             17.27

27/11/2019 16:00             15.19

27/11/2019 17:00             8.02

27/11/2019 18:00             0.97

28/11/2019 07:00             8.67

28/11/2019 08:00             14.7

28/11/2019 09:00             16.91

28/11/2019 10:00             16.7

28/11/2019 11:00             17.51

28/11/2019 12:00             19.25

28/11/2019 13:00             18.94

28/11/2019 14:00             18.77

28/11/2019 15:00             17.57

28/11/2019 16:00             16.72

28/11/2019 17:00             8.47

28/11/2019 18:00             0.51

29/11/2019 07:00             5.18

29/11/2019 08:00             16.81

29/11/2019 09:00             17.33

29/11/2019 10:00             19.16

29/11/2019 11:00             20.95

29/11/2019 12:00             21.2

29/11/2019 13:00             19.89

29/11/2019 14:00             19.66

29/11/2019 15:00             18.79

29/11/2019 16:00             17.51

29/11/2019 17:00             13.35

29/11/2019 18:00             3.68

30/11/2019 06:00             2.69

30/11/2019 07:00             7.69

30/11/2019 08:00             20.85

30/11/2019 09:00             18.53

30/11/2019 10:00             19.36

30/11/2019 11:00             21.86

30/11/2019 12:00             22.9

30/11/2019 13:00             21.98

30/11/2019 14:00             23.06

30/11/2019 15:00             21.35

30/11/2019 16:00             21.88

30/11/2019 17:00             18.47

30/11/2019 18:00             4.85

01/12/2019 06:00             2.18

01/12/2019 07:00             7.54

01/12/2019 08:00             19.59

01/12/2019 09:00             17.43

01/12/2019 10:00             19.74

01/12/2019 11:00             21.38

01/12/2019 12:00             22.03

01/12/2019 13:00             20.35

01/12/2019 14:00             21.51

01/12/2019 15:00             20.04

01/12/2019 16:00             17.78

01/12/2019 17:00             16.24

01/12/2019 18:00             3.53

02/12/2019 06:00             3.43

02/12/2019 07:00             5.35

02/12/2019 08:00             17.93

02/12/2019 09:00             17.99

02/12/2019 10:00             18.13

02/12/2019 11:00             19.98

02/12/2019 12:00             20.14

02/12/2019 13:00             22.02

02/12/2019 14:00             19.9

02/12/2019 15:00             18.66

02/12/2019 16:00             18.37

02/12/2019 17:00             9.2

02/12/2019 18:00             2.94

03/12/2019 07:00             3.34

03/12/2019 08:00             16.43

03/12/2019 09:00             19.66

03/12/2019 10:00             18.05

03/12/2019 11:00             18.41

03/12/2019 12:00             19.26

03/12/2019 13:00             19.15

03/12/2019 14:00             16.94

03/12/2019 15:00             15.91

03/12/2019 16:00             15.63

 

The total of the energy used measure is 1340.46 however my total is showing as 225.26?

 

Please note this is a measure and not a column

Can someone please help?

1 ACCEPTED SOLUTION

Hey @PSRai ,

 

use this DAX for the measure Energy used:

 

SUMX(
	VALUES('tablename'[read_at (bins) Hours])
	, [MAX Energy] - [MIN Energy]
)

 

 

If this does not provide what you are looking for, provid sample data and describe the expected result based on the sample data.

 

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

View solution in original post

14 REPLIES 14
amitchandak
Super User
Super User

Can you share the formula

TomMartens
Super User
Super User

Hey @PSRai ,

 

unfortunately, due to the little information you provided it's not possible to provide you with any guidance.

Post the DAX of the measure and also describe the underlying table, if not the underlying data model.

 

Please consider to provide a pbix file that contains sample data and represents your data model, upload the pbix to onedrive or dropbox and share the link. If you use Excel to create the sample data, upload the xlsx as well.

 

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

Hi 

 

I have a table named readings_true_energy

 

The measure is a made up of two other measures, [MIN Energy] and [MAX Energy], Energy is a column 

 

Energy used is [MAX Energy] - [MIN Energy]

 

The Total doesnt add up 

Hey @PSRai ,

 

use this DAX for the measure Energy used:

 

SUMX(
	VALUES('tablename'[read_at (bins) Hours])
	, [MAX Energy] - [MIN Energy]
)

 

 

If this does not provide what you are looking for, provid sample data and describe the expected result based on the sample data.

 

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany
Anonymous
Not applicable

 

@TomMartens
@sturlaws 
@az38 
@JarroVGIT 


Hi

I am trying to use a DAXmeasure in Matrix report Power BI, but its giving me wrong column total but correct row total. Can you please recommend me is it possible to fix this or it has to be only row total. 

I have provided the screenshort of my measure, report and expected output. 

 

ReportReportCalculationCalculationExpected OutputExpected Output

I am getting above output as my measure is calculating across projects which i want to ignore in the column  total. Can you please suggest the solution for it as I am unable figure out whether its possible or not. 

 

 

Thanks 

 

 

Hi,

Share the link from where i can download your PBI file.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
Anonymous
Not applicable

@Ashish_Mathur 

I need to develop a measure to calculate the effort of the employee in project. Please find the link to download the pbi file.

 

https://drive.google.com/open?id=1PybKLxj26aUZxHwIwVTzBiOUbmaRBDaq

 

 

Requirement

Suppose for employee A 

 

Actual Hour is the sum of the actual Hours that A has spent in both the projects 

Project Hours is the sum of actual hours of all the employees involved in that particular project.

 

Project idActual HoursProject HoursMeasure = Actual/Project
11215012/150
25720057/200

Hi,

You may download the solution file from here.

Hope this helps.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
Anonymous
Not applicable

@Ashish_Mathur 

Thank you for the help, when I try to put this in my solution in the final measure,  I am getting wrong sub total. 

Actually I am trying to multiply Invoicing measure (perfectly working - designed based on many tables as per the business process)

with the measure (employee effort)  to get Employee_Invoice ( which is the final measure) .

 

Final measure = Invoicing * Employee effort 

I am unable to fix the  subtotal error for this.

 

Can you please suggest.

 

Hi,

This measure works

Employee Invoicing = IF(ISBLANK([Invoicing]),BLANK(),SUMX(VALUES('ProjectTicketandtimeEntries Details'[Project Id]),[Invoicing]*[Effort of Employee]))

Hope this helps.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

Hi,

 

Thanks, This has worked. 

Hello @PSRai,

Did you try the solution link that I posted earlier?

@rajulshah 

 

Hi I did yes but still getting the same results unfortunately 

rajulshah
Super User
Super User

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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