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
Anonymous
Not applicable

unable to call the source column without using aggregate functions in measure

unable to call the source column without using aggregate functions in measure...

 

im creating measure and i dont want to use SUM or aggregate functions for MRP_AVAIL_USD_AMT column in measure...

 

thimmaraju_0-1626763249230.png

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , measure mean aggregated value, so you have to some operation like sum , min or max on MRP_AVAIL_USD_AMT 

 

If needed you can create a new column. Only if test is not a measure

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@Anonymous , measure mean aggregated value, so you have to some operation like sum , min or max on MRP_AVAIL_USD_AMT 

 

If needed you can create a new column. Only if test is not a measure

Anonymous
Not applicable

Yes @Amit

 

you are correct..but if i use calculated column then slicer selection filter calculations will not apply 

 

but if i use measure then slicer selection will apply on measure only...below is the dax which im using 

 

MRP_AVAIL_USD_AMT_SINGLE_mea =
// var maxCol =
// CALCULATE(MAX(AZSAT_SHPMT_INVEN_WKLY_VW[Index]), ALLEXCEPT(AZSAT_SHPMT_INVEN_WKLY_VW,AZSAT_SHPMT_INVEN_WKLY_VW[SFU_MATL_ID],AZSAT_SHPMT_INVEN_WKLY_VW[FPC_ID],AZSAT_SHPMT_INVEN_WKLY_VW[fy_mth_id]) )

var test =

CALCULATE(
MAX(
AZSAT_SHPMT_INVEN_WKLY_VW[Index]
),
ALLEXCEPT(
AZSAT_SHPMT_INVEN_WKLY_VW,
AZSAT_SHPMT_INVEN_WKLY_VW[SFU_MATL_ID], AZSAT_SHPMT_INVEN_WKLY_VW[FPC_ID], AZSAT_SHPMT_INVEN_WKLY_VW[fy_mth_id]
),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[BRAND_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[CUST_LVL_4_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[SUB_TRADE_CHANL_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[ATTR_1_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[ATTR_2_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[ATTR_3_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[ATTR_4_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[ATTR_5_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[ATTR_6_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[ATTR_7_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[ATTR_8_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[PROFT_CTR_LVL_5_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[LOCAL_DFU_STTUS_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[LOCAL_MATL_STTUS_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[CATEG_NAME]),
FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[CSU_IND])
,FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[Geolevel_sl]),

FILTERS('distinct subsector'[Subsector]),

FILTERS(AZSAT_SHPMT_INVEN_WKLY_VW[SelectedMarket])
)

return if(test= MAX(AZSAT_SHPMT_INVEN_WKLY_VW[Index]),SUM(AZSAT_SHPMT_INVEN_WKLY_VW[MRP_AVAIL_USD_AMT]))
 

 

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.

Top Solution Authors