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
Kobe100
Frequent Visitor

Grand Total Showing Blank Results ( but each line has the correct value)

Dear Communitity, hope you are doing well.

 

The code below works at the line item level but when it come to the Grand Total there is not result ( Blannk Grand Total)

 

Total_Cost per GL =
VAR CurrentGL = SELECTEDVALUE(Report_Structure[Account])
VAR CurrentYear = SELECTEDVALUE(Report_Structure[Fiscal Year])
RETURN
CALCULATE([Total_COST], Transactional[AccountNumber] = CurrentGL, Transactional[FiscalYear] =CurrentYear )
3dafb2a7-2578-4a1d-8bd3-39cdbf208ca3.jpg
The main: I am using a disconnected table (Report_Structure) to generate measure out of the transactional table.
 
Thank you in advance
1 ACCEPTED SOLUTION
Jihwan_Kim
Super User
Super User

Hi,

I am not sure how your semantic model looks like, but please try something like below whether it suits your requirement.

 

Total_Cost per GL =
VAR CurrentGL =
    VALUES ( Report_Structure[Account] )
VAR CurrentYear =
    VALUES ( Report_Structure[Fiscal Year] )
RETURN
    CALCULATE (
        [Total_COST],
        FILTER (
            Transactional,
            Transactional[AccountNumber]
                IN CurrentGL
                    && Transactional[FiscalYear] IN CurrentYear
        )
    )

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

View solution in original post

2 REPLIES 2
Kobe100
Frequent Visitor

Thank you very much. It works perfectly! 

I will review my code to avoid this to happend again!

 

Jihwan_Kim
Super User
Super User

Hi,

I am not sure how your semantic model looks like, but please try something like below whether it suits your requirement.

 

Total_Cost per GL =
VAR CurrentGL =
    VALUES ( Report_Structure[Account] )
VAR CurrentYear =
    VALUES ( Report_Structure[Fiscal Year] )
RETURN
    CALCULATE (
        [Total_COST],
        FILTER (
            Transactional,
            Transactional[AccountNumber]
                IN CurrentGL
                    && Transactional[FiscalYear] IN CurrentYear
        )
    )

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

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.