SAN FRANCISCO -- Ehire Adrianza became the latest pinch-runner in the majors to make a decisive dash.
"That was so exciting," Adrianza said. "I have been waiting for this moment since I was 3 years old. It was pretty amazing and it feels great. As a pinch-runner it was an honor to win a game like that."
Adrianza has been a minor league shortstop in the Giants' system since he was 16 in 2006.
Javier Lopez (3-2) got the win. Sanchez also drove in a run for the Giants, who split the series with Arizona.
"I just tried to put the ball in play and took advantage of the hole," Sanchez said. "I feel great right now. I'm comfortable swinging. I feel amazing."
Eric Chavez and A.J. Pollack each drove in runs for the Diamondbacks.
"We have not swung the bats very well at all, especially in the good situations," Arizona manager Kirk Gibson said. "We're not in a good streak right now."
Gibson was ejected in the 10th for arguing after first base umpire Tom Hallion reversed his original call.
The Diamondbacks had runners at first and second with two outs when Aaron Hill grounded to first baseman Buster Posey. After bobbling the ball, Posey flipped to pitcher George Kontos covering the bag.
Hallion called Hill safe, then consulted with the other umpires and ruled him out.
Giants starter Madison Bumgarner threw six shutout innings, allowing four hits. He struck out nine and did not walk a batter. Bumgarner remains winless over his last seven starts.
"It doesn't matter if I get the win or not, that's out of our control," Bumgarner said. "All the starters are trying to do is compete, eat up some innings and keep us in it."
Diamondbacks starter Wade Miley went seven innings, allowing two runs on five hits. He walked two and struck out three.
Miley retired nine of the first 10 hitters before running into trouble in the fourth.
Tony Abreu walked and Posey doubled to open the inning. One out later, Sanchez bumped a single into right field to score one run and Posey later scored on a wild pitch.
The Diamondbacks scored twice in the eighth against Santiago Casilla, Chavez hit a sacrifice fly and Pollack had an RBI single.
OF Hunter Pence needs a home run to become the first Giants player to record at least 20 home runs and 20 steals in a season since Barry Bonds in 1998. ... The Giants sold out their 237th regular season home game, doing it while the San Francisco 49ers hosting the Green Bay Packers in their regular-season opener. ... RHP Tim Lincecum (9-13, 4.50) makes the start for the Giants on Monday night when Colorado arrives to open a three-game set. He's 0-2 with an 8.00 ERA against the Rockies this year. ... The Diamondbacks will start RHP Randall Delgado (4-5, 3.69) in their series opener against the Dodgers in Los Angeles on Monday. He's allowed three earned runs or less in 12 of his 15 career starts. ... Arizona IF Martin Prado missed his second straight game with an illness. ... Diamondbacks INF Cliff Pennington returned to Arizona after the game to be with his wife, who will undergo induced labor on Monday.
Brandon Kintzler finished the season as a setup man for the Nationals, but he is drawing plenty of interest as a closer in the free-agent marketplace.
The timing might not be right to get a big return for its star closer, but Baltimore could be left with no choice but to trade him this winter.
Atlanta Braves prospect Ronald Acuna won the Arizona Fall League MVP award after finishing with seven home runs in 23 games for the Peoria Javelinas.
As Toronto looks to add a left-hander to upgrade its bullpen, the Jays are reportedly interested in former Red Sox reliever Robbie Ross Jr.
Baltimore is reportedly eyeing the right-hander, who became a free agent after declining a qualifying offer from the Rays.
Arizona reportedly isn't ruling out a reunion with its closer from last season.