Forum Discussion
Fragmaticx
11 months agoFrequent Visitor
CalculationGroups - switch between dates
Hi I have a model where I use calculaton groups to switch between dates. Lets say its a Order Date and Delivery Date - and I want to make a calculation based of the 2 dates. I think i ...
- 11 months ago
Hi Fragmaticx please try this
Lastmile Cost - Different Period =VAR CurrentCalcItem = SELECTEDVALUE ( 'DateToUse'[Calculation group column] )RETURNCALCULATE (SUM ( BaseData[AmountDKK] ),BaseData[Type] = 2,BaseData[TransportType] = 1,SWITCH (CurrentCalcItem,"OperationalPeriod", BaseData[ShipmentPeriod] <> BaseData[OperationalPeriod],"ShipmentPeriod", BaseData[OperationalPeriod] <> BaseData[ShipmentPeriod]))
techies
11 months agoSuper User
Hi Fragmaticx As i understand, you can try using ISSELECTEDMEASURE where you want change depending on measures shipment based, operational based
Please share sample datasets to test