Interval query.