Forum Discussion
Martin-Prague
8 years agoHelper II
DAX, Disaggregate PLAN data - start date, end date
Hello Comunity, I have source data in this structure: Campaign ID Start date End date Plan
888405244 01.01.2016 31.12.2016 726190
888405244 01.01.2017 31.12.2017 890145
873145821 01.01.2...
- 8 years ago
parry2k
8 years agoSuper User
Martin-Prague to confirm based on your data set, plan for each row will be 365 days, correct?
Martin-Prague
8 years agoHelper II
Hello, no the period is sometimes different, unfortunately. Start date and End date needs to be taken into calculation.
- parry2k8 years agoSuper User
Understood, but in the sample you mentioned it will be difference between dates, and your sample data will return 365 days, correct?
or you want plan value do be divided by different in number of days.
- Martin-Prague8 years agoHelper IIIn my sample, yes. The difference should be 365. But this needs to be dynamic.
When i have Plan only for 1.1.2017 - 15.1.2015 then it shoud be recalculated by 15 for this campaign. And my dataset has also these shorter periods.- parry2k8 years agoSuper User
are you expecintg this output
1 1/1/2016 365 1111
1 1/2/2016 365 1111
1 1/3/2016 365 1111
1 1/4/2016 365 1111
1 1/5/2016 365 1111
....
so basically each campaign is broken down by date, with date difference between start/end date and plan value,c orrect?
above is just an example