Detective Chief Inspector Martin Tate, who is overseeing the investigation into the attack in Hexthorpe on Tuesday morning, said: "Officers worked tirelessly round the clock to investigate. Well done guys."
A 45-year-old officer was knocked unconscious in an alleyway near Sheardown Street.
Dale Francis Cheetham, aged 22, currently of no fixed abode but previously of Bolton upon Dearne, Barnsley, has been charged with grievous bodily harm, two counts of robbery, two counts of possession of a bladed article, possession of an offensive weapon, aggravated vehicle taking without consent, driving whilst disqualified and driving without insurance.
Peter White, 24, of Low Road, Conisbrough, Doncaster, has been charged with robbery.
Both are due in court this morning.