Forum Discussion
processman
8 years agoNew Member
Time Intelligence doubt
I have a project where instead of dividing the year into 12 months I divide it into 18 periods. Then I have a column that joins the year and the period for example 201701 (year 2017, period 01), 2018...
- 8 years ago
Hi processman,
Instead of measure, you could create calculated columns in this scenario.
Year = LEFT(Query[Period],4) Sales previous year Column = CALCULATE ( SUM ( Query[Sales] ), FILTER ( Query, Query[Period] = EARLIER ( Query[Period] ) - 100 ) )Best regards,
Yuliana Gu
MFelix
8 years agoSuper User
Hi processman,
Try something like this:
Sales previous year =
VAR CurrentPeriod =
MAX ( Table[Period] )
RETURN
CALCULATE ( SUM ( Table[Sales] ); Table[Period] = ( CurrentPeriod - 100 ) )This should work based on your columns and explanation.
Regards,
Mfelix
- processman8 years agoNew Member
Thanks for the answer. Actually I need something like this:
- MFelix8 years agoSuper UserHi processman
If you add the measure that i refer and added it to you rable.visual you.will get thst exactly same.look.
Regards,
MFelix- processman8 years agoNew Member
You were right, it looks excellent. Now the problem I have is that by using a year filter, the "sameperiodlastyear" is no longer displayed, since the filter shows information about the chosen year but not the previous one. Is there a way to filter the current year, see the associated data of the previous year?