Forum Discussion
putriwid
6 years agoFrequent Visitor
How to find datediff in the same column with condition
Hello guys, I have a table that consists of 6 columns. the table looks like this: i want to create the measurement on how long the duration when the 'dtstatus'= 1 until the 'dtstatus' changed...
putriwid
6 years agoFrequent Visitor
hello v-diye-msft ,
- i have try using the M code that u gave in power query and it looks like this:
once i click the 'table' on the custom column, it looks exactly like the one that u share.
However, it doesnt show the data from other date.
- Fyi, M code is very unfamiliar for me. Do you have any simpler measurement?
thank you in advance.
v-diye-msft
Community Support
6 years agoHi putriwid
let me specify more detailed steps of the power query:
1. Add the index column from 1 to add the first index column:
2. Inserted the division using divide by 2
3. Round up the values
4. Delete the Division column and change the "Round up" column as "Index 2"
5. Then try the measure I provided before
If you can't fix it, Please kindly share your dummy pbix here (Upload it to dropbox/onedrive and generate the link), that I can draw it up for you.