Forum Discussion
Sorting Date Slicer in Power BI
- 4 years ago
I have created a seperate date table and joined it with the main table to resolve the issue. Thanks for all your help.
Hi writetofaiz
Try Group By function in Power Query.
Firstly Group "All Rows" by [Date] column, sort [Date] column and then add Index column from 1. Then do same steps as above, add an custom column by If to show 0 if [Date] = "Current".
Finally, expand all rows and remove columns you don't need. Result is as below.
Or you can create a new table without duplicate values like my Table1.
You can download my sample for more details.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi,
In my dataset there are multiple columns.
When I grouped by Event date, I got this data and my report went for a toss.
- Anonymous4 years agoNot applicable
Hi writetofaiz,
Group "All Rows" by [Date] column, sort [Date] column and then add Index column is to let same dates with the same Index.
Click expand icon in red box and expand all columns you want, then remove columns you don't need and rename the column names. Then you will get the result you want.
For reference: Work with a List, Record, or Table structured column (Power Query)
You can download my sample above and get more details about expand steps.
Best Regards,
Rico ZhouIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- writetofaiz4 years agoHelper I
I have created a seperate date table and joined it with the main table to resolve the issue. Thanks for all your help.