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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
RilwanFlame
Helper III
Helper III

DAX formula to calculate difference between current Q and previous Q.

Hi all- 

 I have the below data, and looking to calculate the difference between the current Q from the previous Q. 

RilwanFlame_0-1659550969016.png

 

So far, i have the formula: 

QoQ $ =
IF(
    ISFILTERED('ICC Reports'[Date]),
    ERROR("Time intelligence quick measures can only be grouped or filtered by the Power BI-provided date hierarchy or primary date column."),
    VAR __PREV_QUARTER = CALCULATE(SUM('ICC Reports'[$]), DATEADD('ICC Reports'[Date].[Date], -1, QUARTER))
    RETURN
        DIVIDE(SUM('ICC Reports'[$]) - __PREV_QUARTER, __PREV_QUARTER)
)

 

 

 

Thank you

2 REPLIES 2
amitchandak
Super User
Super User

@RilwanFlame , Always use date table if you want time intelligence to work . Joined with date of you table .

Also no .[Date]

 

IF(
ISFILTERED('ICC Reports'[Date]),
ERROR("Time intelligence quick measures can only be grouped or filtered by the Power BI-provided date hierarchy or primary date column."),
VAR __PREV_QUARTER = CALCULATE(SUM('ICC Reports'[$]), DATEADD('Date'[Date], -1, QUARTER))
RETURN
DIVIDE(SUM('ICC Reports'[$]) - __PREV_QUARTER, __PREV_QUARTER)
)

 

Why Time Intelligence Fails - Powerbi 5 Savior Steps for TI :https://youtu.be/OBf0rjpp5Hw
https://amitchandak.medium.com/power-bi-5-key-points-to-make-time-intelligence-successful-bd52912a5b...

Time Intelligence, DATESMTD, DATESQTD, DATESYTD, Week On Week, Week Till Date, Custom Period on Period,
Custom Period till date: https://youtu.be/aU2aKbnHuWs&t=145s
To get the best of the time intelligence function. Make sure you have a date calendar and it has been marked as the date in model view. Also, join it with the date column of your fact/s. Refer :radacad sqlbi My Video Series Appreciate your Kudos.

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Thank you for your response. Below is basically what i am trying to calculate in power BI 

QoQ Change = I5-H5

YTD Change = I5 - G5

RilwanFlame_1-1659708172523.png

 

So far my Power BI calculation:

RilwanFlame_2-1659708299445.png

 

 

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 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.