St. Louis, MO (SportsNetwork.com) - The St. Louis Cardinals scored two runs in the bottom of the ninth to beat the Arizona Diamondbacks 4-3 on Wednesday.

Jason Heyward hit a homer down the right-field line to welcome Brad Ziegler (0-1) to the mound and even the score at three. Peter Bourjos then singled and moved to second when Kolten Wong grounded out. Matt Carpenter was intentionally walked before Matt Holliday walked to load the bases.

"This game is going to beat you up at times, but you gotta put it past you. It's not about you it's about your team. Just take it one at-bat at a time and thank goodness I was able to tie it up," Heyward said.

The Diamondbacks set up a five-man infield. Jhonny Peralta hit a grounder to the third baseman who got the forceout at home, but Jordan Pacheco's wild throw to first allowed the winning run to score.

Pacheco replaced Tuffy Gosewisch, who jammed his left knee while trying to beat out a grounder in the sixth.

The Cardinals swept this three-game series and have won four in a row overall.

St. Louis starter Lance Lynn gave up three runs -- two earned -- on six hits with five strikeouts and four walks over six innings. Seth Maness (1-0) recorded the final two outs in the ninth to pick up the win.

"Like I said to them after the game, they busted their tails all series, all three games. I'm proud of them, but we lost. We have to do better," D-backs coach Chip Hale said.

Josh Collmenter got the start for Arizona and allowed two runs on six hits over five innings.

Wong led off the bottom of the first with a homer to right.

The Cardinals tacked on another run in the second. Yadier Molina hit a ground- rule double to left and raced home on Mark Reynolds' single to center.

Mark Trumbo led off the fourth with a homer to make it 2-1.

St. Louis had a chance to extend its margin in the home half. With the bases loaded and one out, Heyward popped out and Lynn flied out.

Arizona used a two-run sixth to take the lead. Cliff Pennington hit a one-out single and moved to second when Gosewisch grounded out. Nick Ahmed walked and scored from first when Heyward booted the ball on pinch-hitter David Peralta's RBI single to right.

Game Notes

Holliday set a Cardinals franchise record by reaching safely in 43 straight games to start the season, passing Albert Pujols' 2008 standard. It's the longest run in the majors since Derek Jeter set the big-league record with 53 in a row in 1999 ... Cardinals first baseman Matt Adams is expected to miss the next 3-to-4 months while recovering from a severe right quadriceps strain that he suffered running the bases on Tuesday. He was placed on the 15-day disabled list on Wednesday.