end/startdate error fixed