cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
KGBOR
Frequent Visitor

Return measure value for a specific period

I need to apologize for such elementary question (I've just started using Power BI) but I'm struggling with the following.  I have a column in my dataset which can take up a the value of 0 or 1. For this I created a measure which divides the total count of rows with the sum of 1s. So basically if I have 10 rows with 5 having the value of 1, then it gives 50%. Now my problem is, I cannot figure it out how to display this measure only for a specific timeframe, specifically for the current week, current month, last week and last month. I need to display these values on a card visuals. 

 

Thank you for your help!

1 ACCEPTED SOLUTION
johnt75
Super User
Super User

Make sure that you have a date table linked to your fact table, then on your card visuals you can add 'Date'[Date] to the visual filter and use relative date, e.g. is in this calendar month.

View solution in original post

4 REPLIES 4
johnt75
Super User
Super User

Make sure that you have a date table linked to your fact table, then on your card visuals you can add 'Date'[Date] to the visual filter and use relative date, e.g. is in this calendar month.

KGBOR
Frequent Visitor

Thank you very much! If I'd need to have that value as well as a measure, is there any easy was to have that calculated, let's say for the previous month?

 

Thanks again for the help!

I'm afraid I don't understand. Which value do you mean?

KGBOR
Frequent Visitor

My bad, I formulated it incorrectly, in the meantime I figured it out. 🙂

 

Thanks again for the help!

Helpful resources

Announcements
August 2022 update 768x460.jpg

Check it Out!

Click here to learn more about the August 2022 updates!

August 1 episode 9_no_dates 768x460.jpg

The Power BI Community Show

Watch the playback when Priya Sathy and Charles Webb discuss Datamarts! Kelly also shares Power BI Community updates.

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Top Solution Authors
Top Kudoed Authors