Forum Discussion
Adwitiy_4209211
3 years agoNew Member
Questions for optimization and DAX expression
There is one customer column as CUST_CODE which we want to create a calculated column which has the customer value which is filtered based on the REVENUE column. Basically we want just those custom...
tamerj1
3 years agoCommunity Champion
the folowing calculated column returns TRUE for the customers that made revenue.
=
NOT ISBLANK (
CALCULATE (
SUM ( ACT_SALES[Revenue] ),
ALLEXCEPT ( FACT_SALES, FACT_SALES[CUST_CODE] )
)
)Adwitiy_4209211
3 years agoNew Member
Thank you tamerj1 ,
I think I have failed to mention REVENUE is a measure which calculates total Revenue.
Customer is a dimension column.
So based on this I want a calculated column of show customers where REVENUE is not blank.
- tamerj13 years agoCommunity Champion
I understand it is a measure but I guessed it is a sum of a column. However, you can use
= NOT ISBLANK ( CALCULATE ( [Revenue], ALLEXCEPT ( FACT_SALES, FACT_SALES[CUST_CODE] ) ) )