#4137 update batch code