Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hello how are?
I have a problem that I can't solve, I wanted to know if someone comes up with an idea.
I have a table where a period and an ID appear, I need to show in a column the times the ID has been repeated, but taking into account the previous value.
I show you an example so that you can understand it simpler.
Period | ID | Repeated |
202001 | 1234 | 0 |
202001 | 1111 | 0 |
202002 | 4566 | 0 |
202003 | 1234 | 1 |
202004 | 1234 | 2 |
From now on thank you very much for any help!
Solved! Go to Solution.
Thanks for reaching out to us.
if you want to create a column, please try this,
Column =
var _count=CALCULATE(COUNTROWS('Table'),FILTER('Table','Table'[ID]=EARLIER('Table'[ID]) && 'Table'[Period]<EARLIER('Table'[Period])))
return IF(ISBLANK(_count),0,_count)
if you want to create a measure, please try this
measure =
var _count=CALCULATE(COUNTROWS('Table'),FILTER(ALL('Table'),'Table'[ID]=MIN('Table'[ID]) && 'Table'[Period]<MIN('Table'[Period])))
return IF(ISBLANK(_count),0,_count)
Best Regards,
Community Support Team _Tang
If this post helps, please consider Accept it as the solution to help the other members find it more quickly.
Thanks for reaching out to us.
if you want to create a column, please try this,
Column =
var _count=CALCULATE(COUNTROWS('Table'),FILTER('Table','Table'[ID]=EARLIER('Table'[ID]) && 'Table'[Period]<EARLIER('Table'[Period])))
return IF(ISBLANK(_count),0,_count)
if you want to create a measure, please try this
measure =
var _count=CALCULATE(COUNTROWS('Table'),FILTER(ALL('Table'),'Table'[ID]=MIN('Table'[ID]) && 'Table'[Period]<MIN('Table'[Period])))
return IF(ISBLANK(_count),0,_count)
Best Regards,
Community Support Team _Tang
If this post helps, please consider Accept it as the solution to help the other members find it more quickly.
User | Count |
---|---|
98 | |
90 | |
82 | |
73 | |
67 |
User | Count |
---|---|
115 | |
102 | |
98 | |
71 | |
66 |