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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
PaulMoses
Helper I
Helper I

Use of TREATAS

Hello there
Can you please tell me if I use TREATAS correctly?
From the tables in the picture, I would like to create a "Total Amount" column in table "TABLE_DIM_SLICER_DAO", with the total amount of each DAO, using TREATAS. But it's the total amount of the entire column that appears. I do not know why, despite all my checks.
I use this simple DAX formula : 

TotalAmount = 
CALCULATE(SUM(FACT_PAR_DETAIL_REFDATE[LOAN_CNTRT_AMT]); TREATAS(VALUES(DIM_DAO[DAO_NAME]); Table_Dim_Slicer_DAO[DAO_NAME]))

Your help will be extremely valuable.
Thank you

 

1 ACCEPTED SOLUTION

@PaulMoses

 

Try with this one

 

TotalAmount =
CALCULATE (
    SUM ( FACT_PAR_DETAIL_REFDATE[LOAN_CNTRT_AMT] ),
    TREATAS ( { Table_Dim_Slicer_DAO[DAO_NAME] }, DIM_DAO[DAO_NAME] )
)

Regards
Zubair

Please try my custom visuals

View solution in original post

3 REPLIES 3
PaulMoses
Helper I
Helper I

Treatas - 4.JPGTreatas - 2.JPG

 

@PaulMoses

 

Try with this one

 

TotalAmount =
CALCULATE (
    SUM ( FACT_PAR_DETAIL_REFDATE[LOAN_CNTRT_AMT] ),
    TREATAS ( { Table_Dim_Slicer_DAO[DAO_NAME] }, DIM_DAO[DAO_NAME] )
)

Regards
Zubair

Please try my custom visuals

Hello @Zubair_Muhammad

Thank you very much.
It works.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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