Sanitizing downloaded filename

fixing, Sanitizing downloaded filename when using 'date' query.