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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
Sandeep13
Helper III
Helper III

PREVIOUSQUARTER Function not give correct value in Card

Hello,

 

I want to show last QUARTER  amount in my card but its showing blank.

 

In below image you can see I selected 2 years from year filter and all 4 qtrs.

 

In table matrix my measure PQQ is working fine but in Card it gives blank.
But I am expecting values 31794150 which is in RED circle as my previous qrt value.

 

Please let me know how can to fix this.


Thanks in Advance.

 

Sandeep13_0-1686329020651.png

 

 

@power @alexp @ramicortes @powerbi2 @dbaexperts @Anonymous 

5 REPLIES 5
Anonymous
Not applicable

Hi @Sandeep13 ,

 

Please create a new measure:

PQQ 2 = 
IF (
    ISBLANK ( SELECTEDVALUE ( 'Date_table'[Year] ) )
        && ISBLANK ( SELECTEDVALUE ( 'Date_table'[Quarter] ) ),
    CALCULATE (
        [PQQ],
        'Date_table'[Year] = MAX ( 'Date_table'[Year] )
            && 'Date_table'[Quarter] = MAX ( 'Date_table'[Quarter] )
    ),
    [PQQ]
)

 

Best Regards,
Gao

Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

How to get your questions answered quickly --  How to provide sample data in the Power BI Forum

Hi ,

 

Your above dax code is still giving me blank values.

 FYI : In my calender Table I have date till 31 dec 2023.

Sandeep13_1-1686821241847.png

 

Sandeep13_0-1686821169926.png

 

Sandeep13
Helper III
Helper III

@Greg_Deckler  Thanks but your links are very useful but in my case is differenct.
I want to show previous Qtr values in CARD but its showing blank.

 

@Sandeep13 Can you share sample data that can replicate the issue? As text preferrably or a PBIX file link.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...
Greg_Deckler
Community Champion
Community Champion

@Sandeep13 You may find this helpful - https://community.powerbi.com/t5/Community-Blog/To-bleep-With-Time-Intelligence/ba-p/1260000

Also, see if my Time Intelligence the Hard Way provides a different way of accomplishing what you are going for.

https://community.powerbi.com/t5/Quick-Measures-Gallery/Time-Intelligence-quot-The-Hard-Way-quot-TIT...



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

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.