Is there any good way to determine streaks of consecutive events in SQL?
I have a Postgres database. It has two tables that we’re concerned with right now. Users
has a Name
field and an ID
field, and Events
has a UserID
field (FK to Users.ID
), EventType
field (typed as integer
), and Time field (typed as datetime
).