Anderson held the Padres to one run on five hits and two walks in seven innings at Chase Field. After he gave up back-to-back singles to start the game, he retired 11 of the next 12 he faced. Anderson also retired 10 of the final 12 he faced from the fourth through seventh innings.
The right-hander was pulled for a pinch-hitter in the seventh. He left with a one-run lead -- the first time he'd left with a lead this season -- and the D-backs' bullpen could not keep the advantage.
The Padres scored twice in the eighth, once in the ninth and -- after the D-backs snapped Craig Kimbrel's streak of 35 straight converted save chances -- twice in the 12th to win 6-4.
The seven innings matched a career high, but Anderson (0-1) needed just 93 pitches to get there.
"He told me I was done and I felt like I did my job at that point," Anderson said of manager Chip Hale. "I felt like I could probably go another inning, but they're making the decisions and I trust what they're going to do. And we have a good bullpen; they just struggled with it tonight.
"I stuck to my game plan, got early outs and was able to go deep in the game. As a starting pitcher, that's what you want to do, and give your team a chance to win the game."
The D-backs had a chance, and with an unnamed starter and a bullpen that will be leaned on again for Sunday's series finale, Anderson gave the D-backs the type of performance they needed and lowered his ERA to 2.97, best among the team's active starters.
Hale didn't dispute the decision to take Anderson out with only 93 pitches could be questioned.
"It doesn't look good now because of what happened," Hale said. "But to get seven out of him, we were happy to turn it over to our bullpen. We felt good about that. You look back and that's one of the things you think about: should we have left him in? He only had 93 [pitches] and could have gone farther. But at that point it was our decision and we felt good about Oliver [Perez] coming in. ... It didn't work out."
It didn't and likely will have further repercussions Sunday. Hale had to use long relievers Andrew Chafin and Randall Delgado, all but eliminating them from taking the spot start in the series finale. Daniel Hudson is the only other candidate on the active roster -- an additional pitcher likely will be added after Danny Dorn was optioned to Triple-A Reno following the game.
"We're not going to announce that," Hale said of Sunday's starter. "We have an idea of what we're going to do, but we're not going to announce it."
Outside of an injury, burning through his bullpen in a loss was the worst possible scenario with Sunday looming, especially given Anderson's performance.
The only time Anderson was better was the one-run, eight-strikeout outing he had in seven innings at Cincinnati last season. He also took a no-decision in that game, which went 15 innings.
Anderson picked up his first Major League RBI on a single up the middle in the fifth against Tyson Ross. It snapped an 0-for-35 streak.