thinQmaster Virtual testing partner Adaptive practice exams that find your weak spots and drill them. Every answer explained. From $69
Enroll

thinQmaster

Find your exam

Five questions free, before you decide.

Step 1 · choose a vendor

In one of our camps? Your practice exams come with the tuition — they are on your study page already.

Data & Analytics · Intermediate

Half-Open Date Range

A date filter written as >= start AND < end, which includes the start and excludes the end so datetime values are captured correctly.

Definition

Half-open intervals avoid off-by-one-day and time-of-day errors, chain cleanly across periods without overlaps, and remain sargable so indexes and partition pruning work.

Example

WHERE ts >= '2026-10-01' AND ts < '2026-11-01'

Exam tip

Applying a function to the column (WHERE YEAR(ts) = 2026) blocks index use; a half-open range on the raw column does not.

Related terms