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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
Anonymous
Not applicable

Calculating Percentage Change

Hi,

 

I have a dataset similar to the below.

 

DateJob IDJob HoursPercentage Achieved
01/01/2022110010%
02/01/2022110020%
03/01/2022110050%

 

I need to create a calculated colum showing the percentage difference from each job based upon the previous date entry.

 

Below is an example of the required outcome.

 

DateJob IDJob HoursPercentage AchievedPercentage Difference (Calculated column)
01/01/2022110010%10%
02/01/2022110020%10%
03/01/2022110050%30%

 

Any ideas on how this can be achieved?

1 ACCEPTED SOLUTION
Tahreem24
Super User
Super User

@Anonymous Try this measure:

Measure =
VAR Prev_Row = CALCULATE(SUM('Table'[Percentage Achieved]),FILTER(ALL('Table'),'Table'[Date]<=MAX('Table'[Date])))
VAR Diff_ = Prev_Row-SUM('Table'[Percentage Achieved])
VAR Result = IF(Diff_=0,SUM('Table'[Percentage Achieved]),Diff_)
RETURN Result
Capture.JPG

 

 

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard

View solution in original post

4 REPLIES 4
Tahreem24
Super User
Super User

@Anonymous Try this measure:

Measure =
VAR Prev_Row = CALCULATE(SUM('Table'[Percentage Achieved]),FILTER(ALL('Table'),'Table'[Date]<=MAX('Table'[Date])))
VAR Diff_ = Prev_Row-SUM('Table'[Percentage Achieved])
VAR Result = IF(Diff_=0,SUM('Table'[Percentage Achieved]),Diff_)
RETURN Result
Capture.JPG

 

 

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard
PVO3
Impactful Individual
Impactful Individual

First add an index column in Power Query.

Then add DAX column like below

Column =
VAR _index = 'Table'[Index]-1
RETURN

'Table'[Percentage Achieved] -
CALCULATE(MIN('Table'[Percentage Achieved]),FILTER('Table','Table'[Index] = _index))
Anonymous
Not applicable

Thanks for the quick response. How ever my dataset includes an abundence of jobs. For example, rows for 01/01/2022 could countain 50 jobs, indexing would not refer back to specific job ID's.

PVO3
Impactful Individual
Impactful Individual

You can fix this in PQ or DAX.

For PQ solution check this.

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors