Even the loss of the team's best hitter couldn't disrupt the San Diego Padres' winning streak.
Playing without shortstop Everth Cabrera, who exited Sunday's win over Arizona due to a sore left hamstring, San Diego (36-34) still managed its seventh consecutive victory Monday, a 5-3 win over San Francisco (35-34) in 13 innings.
The extra frames were mostly uneventful until Alexei Amarista led off the 13th with a single and eventually scored the go-ahead run on a squeeze bunt from pinch-hitter Andrew Cashner, who will start opposite Cain on Tuesday.
Will Venable also contributed in a big way with a spectacular diving catch on the warning track in center field for the final out in the 12th, taking away what likely would have been the game-winning hit by Juan Perez with a runner on second.
"That was pretty cool," Cashner said. ''I've never had a game-winning RBI. But if Will Venable doesn't have that catch ... it's one of the best catches I've ever seen."
Cabrera could miss the entire series, but San Diego is hoping he won't require a trip to the disabled list. Batting .305 with a team-best 84 hits, Cabrera had been a particularly big factor in the team's recent success, hitting .405 with 12 stolen bases while the Padres won 13 of 19 prior to Monday.
"It's better to miss two or three games here and come back as quick as I can," he told the team's official website. "I feel all right. I feel I can play but I don't want to play at 50 percent. They said we will give it a couple of days and see how I feel."
San Diego was also without Carlos Quentin for the third straight game due to a sore left shoulder. He owns a 1.060 OPS over his last 20 games.
Cain (5-3, 4.70 ERA) has shut down the Padres the last three times he's faced them, going 2-0 with an 0.84 ERA, though this will be the first time he's seen them this season.
The right-hander also seems to have gathered himself after allowing seven runs over six innings at St. Louis on June 1. He's surrendered just one earned run over 13 2-3 innings in two starts since.
Cain yielded two hits over 6 2-3 innings in a 10-0 win at Pittsburgh on Thursday.
"He had good command of all his pitches," San Francisco manager Bruce Bochy said of Cain, who is 7-11 with a 3.17 ERA in 30 starts against the Padres. "He's in a good place right now with his delivery and command. I like where he's at."
The Giants are also dealing with a number of injuries, though Bochy told the team's official website Monday that Marco Scutaro could return to the lineup Tuesday. Batting a team-best .332, Scutaro hasn't played since last Tuesday due to an injured left hand. Bochy also said that Angel Pagan and Pablo Sandoval are nearing the start of rehab assignments and could return to the club Monday for the team's series against the Dodgers.
Cashner (5-3, 3.52) faced the Giants in his first two starts of the season, going 1-1 while giving up three runs in 10 innings.
Buster Posey, who got a day off Monday before entering late as a defensive replacement, is 4 for 9 off Cashner with two homers.