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.
Hello,
I have datasource where I list all audits performed to a project.
I then have a calculated table that filters out the last ones audited in the last 30 days. These are considered "recent". Using the formula below
= Table.SelectRows(#"Renamed Columns", let latest = List.Max(#"Renamed Columns"[AuditDate]) in each Date.IsInPreviousNDays([AuditDate], 30) or [AuditDate] = latest)
But it snaps when a project is audited that was still within those 30 days. This is because it is trying to add the same value twice to in a one-to-one column.
How can I fix it?
Thank you for your help.
Solved! Go to Solution.
Hi,
In this scenario, since you want to get the most recent 30 records from the table, you can create a numeric date key column in your table, and use TOPN() function to create you calcualted table.
Recent 30 Days = TOPN(30,Table,Table[DateKey])
Regards,
Simon
Hi,
In this scenario, since you want to get the most recent 30 records from the table, you can create a numeric date key column in your table, and use TOPN() function to create you calcualted table.
Recent 30 Days = TOPN(30,Table,Table[DateKey])
Regards,
Simon
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 |
---|---|
111 | |
100 | |
80 | |
64 | |
58 |
User | Count |
---|---|
148 | |
111 | |
93 | |
84 | |
66 |