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

Get inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.

Reply
Aditi_R
Frequent Visitor

Calculate difference between 2 rows of the same column according to the selected filter values

Hello everyone,

 

I need help in creating a measure which will result in the difference in 'percentage' for each distinct 'student_id'. (Difference with respect to the 'Exam type' chosen.)

As seen in the image, the difference should be 3, -2 and -5 but I am not getting the expected result.

 

Any suggestions appreciated !

Thanks a lot in advance !!

 

Screenshot 2023-07-10 153702.png

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Aditi_R , I think the offset function can help

Power BI Offset Compare Categories, Time Intelligence MOM, QOQ, and YOY: https://youtu.be/5YMlkDNGr0U

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@Aditi_R , I think the offset function can help

Power BI Offset Compare Categories, Time Intelligence MOM, QOQ, and YOY: https://youtu.be/5YMlkDNGr0U

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Thanks a lot!! It is working just fine.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

March2025 Carousel

Fabric Community Update - March 2025

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