SAN DIEGO - Padres right-hander Joe Wieland jumped up in the dugout and pumped his fist after Drew Stubbs grounded out to end the game.

Wieland paused, though, before continuing celebrating his first big league win, a 4-3 victory against the Colorado Rockies on Wednesday night.

"I put my head down and said a prayer and thanked God for it," Wieland said.

"I had to hold back some tears. It's been a long road. Getting called up, I didn't think it would take 29 months to get the first win. It just makes it that much more special."

Wieland (1-0) was making his second start and fourth appearance since May 6, 2012. He underwent reconstructive surgery on his right elbow in July 2012, forcing him to miss all of 2013 and part of this season. He was recalled from Triple-A El Paso on Sept. 2. He had a no-decision in a start at Colorado on Sept. 6.

Afterward, he stashed away a game ball, his jersey and a lineup card, and got a traditional beer shower.

"It was the best shower ever," said Wieland, 24, who was acquired from Texas along with Robbie Erlin for Mike Adams on July 31, 2011.

"I told Joe that he'd been through a lot the last two years, going through a Tommy John and another minor surgery on the elbow earlier this year, to persevere and keep at it," manager Bud Black said. "Joe's still a young man. He's got a big future ahead of him. He was on a nice track after the trade with Texas. Injuries happen in this game, and that was a big one, for a pitcher."

Tommy Medica hit a three-run home run and a replay-aided double for the Padres, who notched their 76th win with four games to go, matching their victory total from each of the last two seasons.

It was San Diego's 48th home win, setting the franchise single-season record at Petco Park, which opened in 2004.

Colorado's Justin Morneau went 0 for 3 to see his NL-leading average drop two percentage points to .317. Pittsburgh's Josh Harrison went 1 for 5 to drop to .316.

Wieland held the Rockies to three runs and three hits in 5 1-3 innings, struck out five and walked three.

Joaquin Benoit pitched the ninth for his 10th save in

With the Padres trailing 1-0 after Charlie Blackmon homered leading off the game, Medica homered off Yohan Flande into the lower deck on the Western Metal Supply Co. brick warehouse in the left-field corner at Petco Park with two outs in the bottom of the first. It was his ninth. Yangervis Solarte was aboard on a leadoff walk and Yasmani Grandal was on base after getting hit by a pitch.

Blackmon homered to right to open the game, his 19th. It was his fifth this year from the leadoff spot.

The Rockies pulled to 4-3 in the sixth. Wieland walked Rafael Ynoa and Justin Morneau with one out before making way for R.J. Alvarez, who allowed RBI singles to Michael Cuddyer and Corey Dickerson. Cuddyer and Dickerson each had three hits.

"That kid had a good fastball and threw the ball well, a good breaking ball," Rockies manager Walt Weiss said of Wieland. "Of course when they get a lead their bullpen is tough. They start to match up and they got some guys that have put together some real good years out there. So it makes it tough playing from behind against these guys in this place."

Flande (0-6) allowed four runs and four hits in four innings, struck out four and walked one.

Medica doubled down the right-field line in the fourth. It was originally ruled a foul ball by first base umpire Jerry Meals but Padres manager Bud Black challenged and the call was overturned. The Padres loaded the bases but failed to score.

ATTENDANCE

Wednesday's crowd of 38,589 brought the seaso total to 2,196,373, the highest total at Petco Park since 2008.

TRAINER'S ROOM

Padres: Manager Bud Black says he'll give it a day or two before deciding if RHP Odrisamer Despaigne will pitch again. The Cuban defector, a rookie, has a sore right side.

UP NEXT

Rockies: After a day off Thursday, RHP Jordan Lyles (7-3, 4.15 ERA) is scheduled to start Friday night in the opener of a three-game, season-ending road series against the Los Angeles Dodgers. L.A. counters with RHP Roberto Hernandez (8-11, 4.08).

Padres: RHP Andrew Cashner (5-7, 2.21) is scheduled to start Thursday night in the opener of a four-game, season-ending series at San Francisco. Giants counter with RHP Yusmeiro Petit (5-5, 3.63).