toDate is needed to get comparison to work