better date handling in base