Barney came home on a throwing error by Jhonny Peralta in the bottom of the eighth to break a 3-3 tie and give the struggling Cubs a rare back-to-back victory.
Barney had only one hit in the game but it was a double good for two runs in the sixth and gave the Cubs a 3-0 lead that Detroit erased in the seventh on an RBI single by Ramon Santiago and a two-run base hit by Austin Jackson.
Peralta's error in the eighth on a ground ball by Tony Campana handed the loss to Phil Coke (1-3).
Carlos Marmol (1-2) was credited with the win after coming on in relief of James Russell and getting the final two outs in the top of the eighth. Shawn Camp set the Tigers down in order in the ninth for his first save of the season.
2014: NFL Cheerleaders [PHOTOS]
Julius Randle breaks leg during NBA debut