SAN DIEGO -- It might not have been pretty, but any win is a thing of beauty to the struggling Chicago Cubs.
Derrek Lee slid home safely with the go-ahead run on the first of two run-scoring groundouts in the ninth inning and the Cubs snapped a three-game losing streak with a 3-1 win over the San Diego Padres on Thursday night.
The Cubs, second in the National League in batting, had scored a total of two runs in dropping the first two games of the series. Coming into the ninth inning Thursday, Chicago had four hits in its last 25 at-bats with men in scoring position.
"Whatever it takes," said Cubs manager Lou Piniella. "If we can get this darn offense untracked. But it's nice to win a baseball game."
Lee led off with a single off Cla Meredith (1-2) and went to third on a single by Aramis Ramirez. With the Padres' infield playing nearly halfway in, Cliff Floyd hit a grounder to second baseman Marcus Giles, who threw home to try and get Lee. But Giles' throw was slightly high and Lee did a hook slide around catcher Josh Bard to give Chicago a 2-1 lead.
"Unfortunately, the throw was a little higher than I wanted it," said Giles. "I was just trying to get rid of it as quickly as I could. At the same time, Derrek Lee made a pretty good slide."
Padres manager Bud Black defended not playing his infield all the way in.
"We felt a sharply hit ball, we still get the guy at home," Black said. "But the ball wasn't hit all that great."
"It was close, but no question I was safe," Lee said.
The two runs allowed by Meredith broke a scoreless string of 17 2/3 innings by San Diego relievers.
Lee, the NL batting leader at .370, got his first hit in 12 at-bats since he returned to the Cubs' lineup on Tuesday. Lee had been out of action since May 13 with neck spasms.
"It feels good to contribute," said Lee. "It's been frustrating because we haven't been doing a good job of making contact."
The Cubs beat the Padres for the only second time in 12 games, dating back to last year, and ended a six-game losing streak in San Diego.
San Diego's Chris Young retired the first 12 Chicago batters until he gave up a leadoff double in the fifth to Ramirez. Barrett followed with a one-out double to tie the score at 1.
The run was only the second earned run allowed by Young in four home starts covering 27 1/3 innings. Young allowed one run and three hits in seven innings. He struck out a season-high 10 batters with two walks.
Adrian Gonzalez led off the San Diego second with a double and scored one out later on Josh Bard's single for a 1-0 lead.
Jason Marquis matched Young as he allowed up one run on five hits over seven innings. Marquis walked three and had five strikeouts.
- The Cubs' victory was their first at Petco Park since June 5, 2005.
- Padres RF Brian Giles (bruised right knee) missed his fourth straight game.