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.
I need help to exclude last 3 months data and current month data. Example: as of today I need data till 31st May 2023. Please help it's urgent. Thanks!
In Power BI, you can create a DAX measure to filter and exclude the last 3 months' data along with the current month's data. Assuming you have a date column named "Date" in your data table, you can use the following DAX measure to achieve this:
FilteredData = FILTER ( YourTableName, -- Replace with the name of your data table YourTableName[Date] < DATE(YEAR(TODAY()), MONTH(TODAY()), 1) && -- Excludes the current month YourTableName[Date] >= DATE(YEAR(TODAY()), MONTH(TODAY()) - 3, 1) -- Excludes the last 3 months )
Replace YourTableName with the name of your data table. This measure filters the data to include only rows where the date is earlier than the first day of the current month (excluding the current month) and no more than 3 months ago.
You can then use the "FilteredData" measure in your visualizations to display data up to the end of May 2023 if today's date is in June 2023.
it's showing error as name DATE wasn't recognised. I'm working on power query and column name is PMTSUMMARY.......
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 |
---|---|
55 | |
25 | |
23 | |
14 | |
11 |
User | Count |
---|---|
78 | |
63 | |
47 | |
17 | |
12 |