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 August 31st. Request your voucher.

Reply
CB_LV
New Member

Help filtering a measure into 2 separate measures

I am using the following measure in power BI to calculate net upsells in some revenue data:

 

Sum Net Upsell=
/*
See Sum New Customer for detailed information
*/
CALCULATE([AmtUSD minus AmtUSD_pp in Thousands, Annualized]
            ,FILTER(SUMMARIZE(PBI_Transaction
                            , PBI_CustomerKey[CustomerKey]
                            , PBI_DimDate[GLDate].[Year]
                            , PBI_DimDate[GLDate].[Month]
                                , "Sum"
                                     , MAX(PBI_Transaction[AmtUSD])
                                , "Sum_pp"
                                     , [AmtUSD_py Max]
                            )
                    , [Sum_pp] > 5 && [Sum] > 5 
                    )
        )
I am then splitting this out into two separate measures to break out net upsell into the two halves, upsells and downsells, using the two different measures here.
 
Sum Upgrade =
/*
See Sum New Customer for detailed information
*/
CALCULATE([AmtUSD minus AmtUSD_pp in Thousands, Annualized]
            ,FILTER(SUMMARIZE(PBI_Transaction
                            , PBI_CustomerKey[CustomerKey]
                            , PBI_DimDate[GLDate].[Year]
                            , PBI_DimDate[GLDate].[Month]
                                , "Sum"
                                     , MAX(PBI_Transaction[AmtUSD])
                                , "Sum_pp"
                                     , [AmtUSD_py Max]
                            )
                    , [Sum_pp] > 5 && [Sum] > 5 && [Sum_pp] < [Sum]
                    )
        )
 
and 
 
Sum Downgrade =
/*
See Sum New Customer for detailed information
*/
CALCULATE([AmtUSD minus AmtUSD_pp in Thousands, Annualized]
            ,FILTER(SUMMARIZE(PBI_Transaction
                            , PBI_CustomerKey[CustomerKey]
                            , PBI_DimDate[GLDate].[Year]
                            , PBI_DimDate[GLDate].[Month]
                                , "Sum"
                                     , MAX(PBI_Transaction[AmtUSD])
                                , "Sum_pp"
                                     , [AmtUSD_py Max]
                            )
                    , [Sum_pp] > 5 && [Sum] > 5 && [Sum_pp] > [Sum]
                    )
        )
 
It seems this would work, but the upsell and downsell measures do not tie out to the net upsell measures. Please help. Thanks!
 
 
1 ACCEPTED SOLUTION
v-chenwuz-msft
Community Support
Community Support

Hi @CB_LV ,

 

Maybe you can try NOT().

 

Sum Downgrade =
/*
See Sum New Customer for detailed information
*/
CALCULATE([AmtUSD minus AmtUSD_pp in Thousands, Annualized]
            ,FILTER(SUMMARIZE(PBI_Transaction
                            , PBI_CustomerKey[CustomerKey]
                            , PBI_DimDate[GLDate].[Year]
                            , PBI_DimDate[GLDate].[Month]
                                , "Sum"
                                     , MAX(PBI_Transaction[AmtUSD])
                                , "Sum_pp"
                                     , [AmtUSD_py Max]
                            )
                    , [Sum_pp] > 5 && [Sum] > 5 && NOT( [Sum_pp] < [Sum] )
                    )
        )
 

Best Regards

Community Support Team _ chenwu zhu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

View solution in original post

1 REPLY 1
v-chenwuz-msft
Community Support
Community Support

Hi @CB_LV ,

 

Maybe you can try NOT().

 

Sum Downgrade =
/*
See Sum New Customer for detailed information
*/
CALCULATE([AmtUSD minus AmtUSD_pp in Thousands, Annualized]
            ,FILTER(SUMMARIZE(PBI_Transaction
                            , PBI_CustomerKey[CustomerKey]
                            , PBI_DimDate[GLDate].[Year]
                            , PBI_DimDate[GLDate].[Month]
                                , "Sum"
                                     , MAX(PBI_Transaction[AmtUSD])
                                , "Sum_pp"
                                     , [AmtUSD_py Max]
                            )
                    , [Sum_pp] > 5 && [Sum] > 5 && NOT( [Sum_pp] < [Sum] )
                    )
        )
 

Best Regards

Community Support Team _ chenwu zhu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

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

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

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