The Colorado Rockies' late-season surge set up one wild finish.
The Rockies will face San Diego in a one-game tiebreaker for the NL wild-card spot Monday night, forcing the playoff with a 4-3 win Sunday over the NL West champion Arizona Diamondbacks.
A single by would-be batting champion Matt Holliday set up the Rockies' go-ahead, three-run burst in the eighth inning, then closer Manny Corpas held off Arizona's two-run rally in the ninth for the Rockies' 13th win in 14 games.
San Diego and Colorado will play at Coors Field for the final playoff spot in the majors.
The Padres, who missed a chance to clinch the slot by losing their last two games at Milwaukee, plan to pitch ace Jake Peavy. The Rockies will counter with Josh Fogg, whose tendency to beat other teams' aces of late has earned him the nickname "Dragon Slayer."
Momentum is nice, Holliday said, but it won't matter come Monday.
"I don't think anything will help us tomorrow other than going out and getting hits off Jake Peavy," Holliday said. "Everything's out the window. Tomorrow's one game. Everything in the last two weeks is in the past and now we've got to focus on beating the Padres for a chance to go to the playoffs."
This will be baseball's first one-game playoff since 1999, when the New York Mets beat Cincinnati 5-0 for the NL wild card.
Holliday went 1-for-3 and is hitting a league-leading .340. He leads Atlanta's Chipper Jones by three points for the batting title — Monday's playoff counts as a regular season game, and Holliday will win the crown provided he doesn't go 0-for-5.
Holliday has his mind on matters much more important than that, however.
"It's not even close. We've got our playoff lives on the line," said Holliday, who led the league in doubles, hits and total bases and has a chance to leapfrog Ryan Howard on Monday for the RBI title, too.
Peavy has a chance to join Boston's Josh Beckett as the only 20-game winners in the majors this year. But even if he does, the Padres would head into the divisional playoffs with their ace unavailable for Game 1.
Looking like they were out of contention just two weeks ago, the Rockies rallied to catch the Padres. San Diego missed its chance to clinch Sunday with an 11-6 loss.
The Rockies, who have won franchise-best 89 games, have been to the postseason just once, in 1995 when they lost to Atlanta in the first round.
Ubaldo Jimenez, a 23-year-old rookie with a 100-mph fastball, allowed one hit and struck out a career-high 10 in 6 1-3 spectacular innings. He left after walking two batters with one out in the seventh, and Carlos Quentin hit an RBI single off Jorge Julio that made it 1-all.
Former closer Brian Fuentes (3-5) came on to strike out pinch-hitter Conor Jackson, one of several Arizona regulars who didn't start, then fanned pinch-hitter Jeff Cirillo. That ended a nerve-wracked inning in which every Rockies player was crouched at the dugout railing and manager Clint Hurdle popped three fresh pieces of gum into his mouth.
Fuentes pitched his way into and out of trouble in the eighth, when he issued back-to-back walks with two outs before striking out Jeff Salazar.
In the bottom half, Troy Tulowitzki reached on third baseman Mark Reynolds' throwing error and Holliday's bad-hop single off first baseman Robby Hammock's glove put runners at the corners with nobody out.
Lefty Bill Murphy replaced Dustin Nippert (1-1) and walked Todd Helton to load the bases moments after the Padres' loss was posted on the scoreboard.
"I knew it wasn't the Broncos game," Hurdle said.
Garrett Atkins followed with a sharp single to left-center that gave Colorado its first lead of the day and left the bases full for Brad Hawpe's two-run double.
Hawpe was a .203 hitter against left-handers coming in. He delivered two hits against them, including an RBI double in the sixth.
"Lately, it's either do or die," Hawpe said. "It's either get a hit off a left-hander, right-hander or a guy who kicks it up there. You've got to do it now or you're going to be home watching games on TV."
The Diamondbacks, who will open the playoffs Wednesday against the Chicago Cubs, weren't done.
Miguel Montero led off the ninth with a single, Quentin doubled and pinch-hitter Augie Ojeda had a sacrifice fly. Alberto Callaspo hit an RBI single with two outs and two strikes before Stephen Drew grounded back to Corpas, who made a brilliant barehanded play and fired to first.
Corpas got his 19th save in 20 chances since inheriting the closing role following Fuentes' June swoon, when he blew four straight saves on a 1-9 road trip that forced the Rockies to play catch-up the rest of the season.
The Padres' game in Milwaukee started an hour earlier than the one at Coors Field, and San Diego was already leading the Brewers 3-0 when the game in Denver began.
"What's kind of tough about it is worrying about their game, but you've got to worry about your own, too," Helton said.
By the time the Rockies came up in the bottom of the second, the Brewers had tied it and soon grabbed the lead. The Coors Field crowd went crazy every time they saw the manual scoreboard operator put up another number for the Brewers.
"I normally don't look at the scoreboard," Hurdle said. "I looked at the scoreboard 3,482 times today. Whenever the ball wasn't in play I caught myself. It was sick."
The Diamondbacks, who on Saturday clinched home-field advantage throughout the NL playoffs, sat most of their regulars and skipped left-hander Doug Davis' scheduled start to save him for the playoffs. Rookie Yusmeiro Petit allowed five hits over five innings.
"They are going to use all of their guys and go as hard as they can. They had to win. There were several guys we weren't going to use," Melvin said. "It's not that uncommon for that to happen at this time of the year."
Colorado went 71-46 after May 22, when they were 8 1/2 games back in the wild card race. Only the Yankees (74-45) were better in that span.
"We still haven't finished it," Helton said. "One hundred sixty-three games. It all comes down to tomorrow."