update date to datetime