« first day (1804 days earlier)      last day (854 days later) » 

2:46 AM
@terbubbs in that case you could just join AnotherTable instead of putting it inside a subquery
and make the ON clause do the work of the subquery's WHERE clause plus the derived table's JOIN
 

« first day (1804 days earlier)      last day (854 days later) »