Counting the number of rows between transitions of values in SQL

后端 未结 0 1582
慢半拍i
慢半拍i 2021-01-29 05:20

I have rows with user_id, timestamps and YES / NO answer. I want to count how many streaks (consecutive rows) of "NO"s each ID has.

Example:

相关标签:
回答
  • 消灭零回复
提交回复
热议问题