Tags / gaps-and-islands
Removing Consecutive Duplicates in Oracle SQL Using LAG() with a Condition
Grouping Consecutive Rows Based on One Column Using SQL Row Number Functions
SQL Running Total with Cumulative Flag Calculation Using Common Table Expression
Finding Oldest Date Range without Gap: A Step-by-Step Solution
Finding the Longest Negative Series in PostgreSQL: A Step-by-Step Solution