James McDonald (2-2) made the lead hold up for the Pirates, limiting San Diego to two runs on five hits, walking one and fanning five in six innings.
Joel Hanrahan gave up a pair of hits in the ninth but managed his ninth save when he got Will Venable on a grounder to end the game and preserve the Bucs' win in the first of a three-game set.
Aaron Harang (4-2) absorbed the loss, surrendering four runs on five hits over five innings.
Jorge Cantu smacked a two-run homer for the Padres.
Astronomers offer more expansive view of universe
LGBT community has 'bullied the American people': Bachmann