SQL for Time-Series: How to JOIN Tables on Overlapping Date Ranges SQL for Time-Series: How to JOIN Tables on Overlapping Date Ranges Most SQL JOINs use the `=` sign (equi-joins). However, real-world data, especially time-series and event data, requires a **non-equi JOIN**—a join based on comparison operators like $>, A classic use case is matching a transaction date to an active promotion period, or an employee's task to their scheduled shift time. The Non-Equi JOIN Syntax To join two tables, `Events` (with a single event date) and `Periods` (with a start and end date), the `ON` clause must check if the event date is within the period's range. Example: Event within a Period We want to find which promotional period (P) was active when a customer placed an order (E): SELECT E.OrderID, E.OrderDate, P.P...