ATLANTA — Freddie Freeman hit a two-run homer in the ninth inning to put the Atlanta Braves back in the playoffs with a 4-3 victory over the Miami Marlins on Tuesday night.

ATLANTA — Freddie Freeman hit a two-run homer in the ninth inning to put the Atlanta Braves back in the playoffs with a 4-3 victory over the Miami Marlins on Tuesday night.

Freeman's drive off Mike Dunn clinched at least an NL wild-card berth for the Braves, who squandered a big lead in the wild-card race with a huge collapse last September.

Longtime star Chipper Jones, who plans to retire at the end of the season, led off the ninth with a double. He moved to third on a wild pitch by Dunn (0-3) and scored when Freeman's 22nd homer easily cleared the center-field wall.

Craig Kimbrel (3-1) worked a scoreless inning to help the Braves win their 22nd straight game started by Kris Medlen. The streak is the longest in the majors since the New York Yankees won 22 consecutive games started by Whitey Ford in 1950 and '53.

Diamondbacks 7, Giants 2

At San Francisco, Paul Goldschmidt hit a three-run homer and a pair of sacrifice flies for a career-high five RBIs.

Goldschmidt on his own gave Josh Collmenter (5-3) plenty of support as Arizona won for the seventh time in its last nine games. The D-backs are trying to keep their slim NL wild-card hopes alive.

Tim Lincecum (10-15) had his start pushed back two games from Sunday after San Francisco clinched its second division crown in three years with a win against San Diego on Saturday night.

The two-time NL Cy Young Award winner lost for the first time in five starts since Aug. 26 at Atlanta. He had won his previous two outings and three straight decisions.

Reds 4, Brewers 2

At Cincinnati, Johnny Cueto pitched seven solid innings, and the Cincinnati Reds stayed in the chase for the NL's top record by beating Milwaukee after learning they'll be without their manager for the rest of the week.

Padres 2, Dodgers 1

At San Diego, Josh Beckett lost for the third time in six starts with Los Angeles, whose playoff chances were dealt a blow.

With eight games to play, the Dodgers are tied with Milwaukee, 41/2; games behind St. Louis for the NL's second wild-card spot. St. Louis beat Houston 4-0 and Cincinnati beat the Brewers 4-2.

Phillies 6, Nationals 3

At Philadelphia, Darin Ruf homered for his first major league hit, Carlos Ruiz and Domonic Brown also went deep as Philadelphia beat playoff-bound Washington.

Cole Hamels (16-6) overcame five shaky innings to set a career high in wins and help the five-time defending NL East champion Phillies keep their faint postseason hopes alive. Hamels allowed three runs and seven hits, tying his shortest outing of the year.

Pirates 10, Mets 6

At New York, Pedro Alvarez hit his 30th homer and drove in four runs as Pittsburgh ended the Mets' four-game winning streak.

Cardinals 4, Astros 0

At Houston, Jaime Garcia pitched seven sharp innings and Jon Jay drove in two runs to help St. Louis improve its playoff chances.

The Cardinals won their fourth straight and extended their winning streak over the last-place Astros to a franchise-best 10 games. They also moved 41/2; games ahead of Milwaukee in the race for the second NL wild card. The Brewers lost in Cincinnati 4-2.

Rockies 10, Cubs 5,6 1/2 innings

At Denver, DJ LeMahieu had three hits and finished a home run short of the cycle and Wilin Rosario went deep for Colorado in a rain-shortened game.

Matt McBride homered and Chris Nelson had three hits for the Rockies, who won a matchup of two 94-loss teams. Carlos Torres (5-3) got the win after allowing one run in two innings of relief.

Tigers 2, Royals 0

At Detroit, Anibal Sanchez threw his first shutout in over a year, and Detroit moved into a tie for first place in the AL Central with a victory over Kansas City.

Sanchez (4-6) retired the first 11 hitters he faced and allowed only three hits. He struck out 10 and walked one.

He threw 105 pitches in his first shutout since Sept. 10, 2011, when he tossed a one-hitter for Florida at Pittsburgh.

Indians 4, White Sox 3

At Chicago, Chicago gave Detroit an opening to tie for the AL Central lead when Gordon Beckham hit into a game-ending forceout with the potential tying run on second base in the loss to last-place Cleveland.

Down 4-0, the White Sox closed when A.J. Pierzynski and Dayan Viciedo hit consecutive fifth-inning home runs off Corey Kluber (2-4) and then pulled within a run when Paul Konerko homered off Chris Perez leading off the ninth.

Twins 5, Yankees 4

At Minneapolis, Phil Hughes ran out of gas in the seventh inning and Boone Logan couldn't hold the lead for him as New York missed a chance to go up 21/2; games on Baltimore.

Hughes (16-13) was strong through six innings and the Yankees took a 3-1 lead. But he left with the bases loaded and two outs in the seventh, and Logan let one run score on a wild pitch before giving up a two-run double to Denard Span that put the Twins in front.

Blue Jays 4, Orioles 0

At Baltimore, Aaron Laffey and five relievers combined on a six-hitter as Toronto beat Baltimore for the second straight game.

Rays 5, Red Sox 2

At Boston, David Price struck out a season-high 13 and Jeff Keppinger hit a three-run homer as Tampa Bay extending its winning streak to six games and kept its playoff hopes alive.

Tampa Bay remained three games behind Oakland for the AL's second wild-card spot. The Athletics beat Texas 3-2 in 10 innings.

Athletics 3, Rangers 2,10 innings

At Arlington, Texas, George Kottaras hit a leadoff homer in the 10th inning and Oakland moved within four games of the AL West lead by beating first-place Texas.

The A's remained two games ahead of Los Angeles for the second AL wild-card spot. The Angels beat Seattle 5-4.

Angels 5, Mariners 4

At Anaheim, Calif., Zack Greinke had a season-high 13 strikeouts in five innings, and Los Angeles got home runs from Torii Hunter and Erick Aybar to remain two games behind Oakland for the second AL wild card.

According to ESPN Stats, Greinke (6-2) became the first pitcher in the live-ball era (since 1920) to strike out 13 batters in a start that lasted only five innings. Randy Johnson had 13 through his first five frames on July 4, 2001, for Arizona against Houston, but he threw one more inning.