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.
Hi
I have a line graph which has to measures in it to show the trend for Penetration - however i need to duynamically exclude current month
is there a way to do that?
Solved! Go to Solution.
Hi @Anonymous
I did a local test ,you can take a reference
Here is my test table
First I created a calendar table
Then create a one-to-one relationship between these two tables
Then I create the measure
IE Pen = DIVIDE(SUM('Table'[sales]),SUM('Table'[reg]),0)
Then I create the measure
Measure = CALCULATE([IE Pen],FILTER('calendar', (10*YEAR('calendar'[Date])+'calendar'[Date].[MonthNo]) < (10*YEAR(TODAY())+MONTH(TODAY()))))
Then in visualization,I create a line chart :
We can see from the line chart ,there is no data in June 2022
If we change the graph to table,we can also see that the current month data is excluded
Best Regards,
Community Support Team _Isabella
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous
I did a local test ,you can take a reference
Here is my test table
First I created a calendar table
Then create a one-to-one relationship between these two tables
Then I create the measure
IE Pen = DIVIDE(SUM('Table'[sales]),SUM('Table'[reg]),0)
Then I create the measure
Measure = CALCULATE([IE Pen],FILTER('calendar', (10*YEAR('calendar'[Date])+'calendar'[Date].[MonthNo]) < (10*YEAR(TODAY())+MONTH(TODAY()))))
Then in visualization,I create a line chart :
We can see from the line chart ,there is no data in June 2022
If we change the graph to table,we can also see that the current month data is excluded
Best Regards,
Community Support Team _Isabella
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@isabella Hi thanks for your help
The formula worked perfectly - however im trying to replicate it for UK now and UK pen is exactly the same as IE pen formula however it will not exclude current month
Hello @Anonymous ,
Please try the following measure and let me know if it works:
IE Pen Current Month =
CALCULATE(
[IE Pen],
FILTER('Calendar',MONTH('Calendar'[Dates]) = MONTH(TODAY())),
FILTER('Calendar',YEAR('Calendar'[Dates]) = YEAR(TODAY()))
)
Hi - no that does work thank you
I need the measure to show everything except for Current month
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
107 | |
98 | |
77 | |
66 | |
53 |
User | Count |
---|---|
144 | |
104 | |
100 | |
86 | |
64 |