Date Range Predicates
Date range predicates evaluate values that represent a start and end date (an interval).
They are commonly used for bookings, schedules, availability windows, validity periods, and similar constructs.
Category: Range-start
Starts after
True if the start of the interval occurs after the configured date.
Example
- Interval:
2025-02-10 → 2025-02-12 - Parameter:
2025-02-01 - Result: ✔ (the interval starts after February 1st)
Starts before
True if the start of the interval occurs before the configured date.
Example
- Interval:
2025-02-10 → 2025-02-12 - Parameter:
2025-03-01 - Result: ✔
Starts at
True if the start of the interval is exactly equal to the configured date.
Example
- Interval:
2025-05-01 → 2025-05-03 - Parameter:
2025-05-01 - Result: ✔
Starts within
True if the start of the interval falls inside a configured date range.
Example
- Parameter range:
2025-05-01 → 2025-05-31 - Interval starts:
2025-05-10 - Result: ✔
Starts anytime after
True if the interval starts anytime later than the configured date.
This is similar to “Starts after” but is often used in broader business logic contexts.
Example
- Parameter:
2025-01-01 - Interval starts:
2025-12-01 - Result: ✔
Tip
Useful for filtering upcoming events or future availability windows.
Category: Range-end
Ends after
True if the end of the interval occurs after the configured date.
Example
- Interval:
2025-02-10 → 2025-02-20 - Parameter:
2025-02-15 - Result: ✔ (the interval ends after Feb 15)
Ends before
True if the end of the interval occurs before the configured date.
Example
- Interval:
2025-02-10 → 2025-02-12 - Parameter:
2025-02-15 - Result: ✔
Ends at
True if the end of the interval matches the configured date exactly.
Example
- Interval:
2025-03-01 → 2025-03-10 - Parameter:
2025-03-10 - Result: ✔
Category: Range-state
Has started
True if the interval has already begun relative to today.
Example
- Today:
2025-01-10 - Interval:
2025-01-05 → 2025-01-20 - Result: ✔
Note
If the interval starts today, it is considered started.
Has ended
True if the interval has already ended relative to today.
Example
- Today:
2025-01-10 - Interval:
2024-12-01 → 2025-01-05 - Result: ✔
Is active now
True if today falls inside the interval (inclusive).
Example
- Today:
2025-01-10 - Interval:
2025-01-05 → 2025-01-20 - Result: ✔
Tip
Ideal for availability checks, licenses, or active status windows.
Category: Range-relationship
Intersects
True if the interval overlaps with the configured interval in any way.
This includes partial overlap, full containment, and touching boundaries.
Example
- Interval A:
2025-01-10 → 2025-01-20 - Interval B:
2025-01-20 → 2025-01-25 - Result: ✔ (end of A touches start of B)
Note
Intervals are inclusive at both ends.
Category: Duration
Has duration equal to
True if the length of the interval matches the configured duration.
Example
- Interval:
2025-05-01 → 2025-05-04 - Duration:
3 days - Result: ✔
Has duration longer than
True if the interval lasts longer than the configured duration.
Example
- Interval:
2025-05-01 → 2025-05-10 - Duration:
5 days - Result: ✔
Has duration shorter than
True if the interval lasts less than the configured duration.
Example
- Interval:
2025-05-01 → 2025-05-03 - Duration:
5 days - Result: ✔
Tip
Useful for filtering events by length, such as “short visits,” “long stays,” or “multi-day tasks.”