Don't miss your chance to take the Fabric Data Engineer (DP-600) exam for FREE! Find out how by attending the DP-600 session on April 23rd (pacific time), live or on-demand.
Learn moreNext up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now
Hi,
I have a list of snapshots and the created dates. I would like to have the list (to export) and total of snapshots that were created between > 5d - 10d, >10d - 30d, >30d - 3months, >3 months.
| created | snapshot |
| > 5d - 10d | 20 |
| >10d - 30d | 40 |
| >30d - 3months | 10 |
>3 months. | 4 |
Thank you in advance.
Tg
Solved! Go to Solution.
Hi @vnqtrang
Assume you want to calculate the days between created date and today, you can add a new column similar to below column. Then add a table visual to the report, add Created and Snapshot ID columns to it and select Count aggregation on Snapshot ID.
Created =
VAR _days = DATEDIFF('Table'[Created Date], TODAY(), DAY)
RETURN
SWITCH(TRUE(),
_days<=5, "<5d",
_days<=10, ">5d - 10d",
_days<=30, ">10d - 30d",
">30d")
Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.
Hi @vnqtrang
Enter a table with Index column. Then sort Created by Index. Sort one column by another column in Power BI - Power BI | Microsoft Docs
Create a relationship between tables on Created column. Then use SortTable's Created column in the table visual instead.
Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.
Hi @vnqtrang
Assume you want to calculate the days between created date and today, you can add a new column similar to below column. Then add a table visual to the report, add Created and Snapshot ID columns to it and select Count aggregation on Snapshot ID.
Created =
VAR _days = DATEDIFF('Table'[Created Date], TODAY(), DAY)
RETURN
SWITCH(TRUE(),
_days<=5, "<5d",
_days<=10, ">5d - 10d",
_days<=30, ">10d - 30d",
">30d")
Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.
HI,
Is it possible to filter the option in order of time:
| <=5d | |
| > 5d - 10d | |
| >10d - 30d | |
| >30d - 3months | |
>3 months. |
Because the option "> 5d - 10d" is at the end, i should be below <=5d
Tg
Hi @vnqtrang
Enter a table with Index column. Then sort Created by Index. Sort one column by another column in Power BI - Power BI | Microsoft Docs
Create a relationship between tables on Created column. Then use SortTable's Created column in the table visual instead.
Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.
Thank you it works as I wish.
could you pls provide the sample data?
Proud to be a Super User!
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
| User | Count |
|---|---|
| 47 | |
| 44 | |
| 39 | |
| 20 | |
| 15 |
| User | Count |
|---|---|
| 70 | |
| 68 | |
| 32 | |
| 27 | |
| 25 |