[v3.4] convert datetimes to date for proper calculation

Resolves #876