Forum Discussion

ItoDiaz's avatar
ItoDiaz
Helper I
4 years ago
Solved

Date sort with query M

Hello everyboby, 

 

I'm a little bit disappointed as I have tried to do a "Date Sort" table using query M. I have followed the procedure described in this post : 

 

https://blog.crossjoin.co.uk/2016/05/30/creating-current-day-week-month-and-year-reports-in-power-bi-using-bidirectional-cross-filtering-and-m/amp/ 

 

I have adapted this code to have date sorts I need. I have followed all the steps, but when I create my slicer to apply my sorts, it doesn't works 😞

 

I have made these relationships like the blog suggest. The main difference is that in the blog's "Data" table there is just a row by date, in my case, I have severals attributs for the same datatime (I have changed the type to date for visuals porpuses), it means several rows for a same datetime. I have tried to change the relationships without sucess. 

I have tried spliting my "Period" table but it doesn't works either. 

 

Can someone give me some suggestions or solutions to solve this problem? 

 

Thanks in advance. 

2 Replies