Handles date comparisons (untested).