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

Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM. Register now.

Reply
Anonymous
Not applicable

Difference between 2 values in a Matrix Table

Hi, 

 

I am trying to create a matrix column (diff) that holds the values of what the difference is between two year columns. Example:

 

2015        2016            *Diff

________    _______        ______

10              6                -4

23             15               -8

187           195            +8

25             30              +5

 

What measures would I be using? I created these:

 

2015 = CALCULATE(COUNT('Phone Leads'[Calls]), Dates[year] = "2015")

2016 = CALCULATE(COUNT('Phone Leads'[Calls]), Dates[year] = "2016")

 

Diff in Years = [2016]-[2015]

 

But I'm getting this error message:

 

 Difference Error.png

 

Any advice?

1 ACCEPTED SOLUTION
MFelix
Super User
Super User

Hi @Anonymous,

Your year column mist be formatted as number take out the quotation marks only put 2016 not "2016" should work.

Regards,
Mfelix

Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



View solution in original post

2 REPLIES 2
MFelix
Super User
Super User

Hi @Anonymous,

Your year column mist be formatted as number take out the quotation marks only put 2016 not "2016" should work.

Regards,
Mfelix

Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



Anonymous
Not applicable

Thanks Mfelix !

Helpful resources

Announcements
October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.