Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
I have a table, 'Risks'.
In this table I have a column, 'Date', which gives a range of dates across 2018.
I also have a second column, 'Type', which gives the type of event associated with that date. The values are either 'Open' or 'Closed'.
I want to create a measure that calculates how many 'Open' events occured since a fixed date '01/01/2018' and Today.
I have tried to create this measure but have had no luck. Does anyone have any ideas?
Thanks
Solved! Go to Solution.
Try something like this:
OpenEvents = CALCULATE ( COUNTA ( Table1[Type] ), Table1[Date] >= DATE ( 2018, 1, 1 ), Table1[Date] <= TODAY (), Table1[Type] = "Open" )
@shaunguyver - Hi
Please create a Calendar Table and relate it to your Risks Table
Then try this measure
Instances =
CALCULATE (
COUNT ( Risks[Date] ),
DATESBETWEEN ( Calendar[Date], DATE ( 2018, 1, 1 ), TODAY () ),
Risks[Type] = "Open"
)
If you would like to have a unique count of the date then replace the COUNT with DISTINCTCOUNT
Hope this helps
Try something like this:
OpenEvents = CALCULATE ( COUNTA ( Table1[Type] ), Table1[Date] >= DATE ( 2018, 1, 1 ), Table1[Date] <= TODAY (), Table1[Type] = "Open" )
Hi lets try.
MEASURE =
calculate(count(Table[Type]),datesbetween(table[Date],01/01/2018,today())
If it solve please mark as solved and give me your positive feed back.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
83 | |
75 | |
64 | |
39 | |
34 |
User | Count |
---|---|
107 | |
56 | |
52 | |
48 | |
40 |