some fixes to date2