SAN JOSE — Led by Tyler Ervin’s school-record 300 yards rushing, San Jose State ran all over archrival Fresno State 49-23 on Saturday night at Spartan Stadium.

Ervin rushed 42 times, one shy of the SJSU single-game carries record, and scored three touchdowns while breaking Nathan Dupree’s mark of 286 yards at UNLV in 1992.

“It’s a blessing,” Ervin said. “All those guys — our fullbacks, our tight ends, our offensive linemen — did a good job blocking. My job is just to get through the holes they create, and I try to do that to the best of my ability.”

The win was SJSU’s third in the past four meetings against the Bulldogs. Before this stretch, the Spartans had defeated their rivals just twice in 20 years.

Ervin’s performance all but eclipsed a stellar effort by senior quarterback Joe Gray. Called on to start in place of the injured Kenny Potter, who was sidelined by a sprained ankle, Gray carved up Fresno State’s defense, completing 20 of 23 passes for 252 yards and a career-high three touchdowns for the Spartans (2-2, 1-1 Mountain West Conference).

Gray accomplished this despite getting sacked six times.

“I told him, ‘You don’t have to be Superman out there,'” San Jose State coach Ron Caragher said. “Just go out, be our point guard and distribute the ball.”

Caragher wouldn’t say that he has a quarterback controversy on his hands given how Gray played Saturday night. However, he did say that having two quarterbacks who can ably serve as starters is a nice problem to have.

“We’ve seen thus far that you need more than one quarterback to play this physical game we play,” the coach said. “Both can move the football and put points on the board.”

In beating Fresno State (1-3, 0-1), the Spartans snapped a number of losing streaks.

San Jose State had lost its two previous games, but that was only the tip of the iceberg. The Spartans also ended an eight-game losing streak to teams in the NCAA’s Football Bowl Subdivision and a six-game streak against conference opponents that dated to Nov. 1 of last year.

Auburn (2-2), a traditional Southeastern Conference power that was ranked earlier this season, awaits next Saturday. For the moment, however, SJSU is a winner again.

Gray excelled from the outset, going 14-of-16 for 181 yards and a touchdown in the first half. He was 3-for-3 for 32 yards on SJSU’s opening drive as he guided the Spartans 73 yards on 11 plays.

Ervin, who finished the first half with 116 yards on just 10 carries, capped the drive with a two-yard touchdown run. He then added another 2-yard TD near the end of the first quarter to give the Spartans a 14-0 lead.

Fresno State pulled within a touchdown in the second quarter when junior quarterback Ford Childress connected with freshman wide receiver Jamire Jordan for a 7-yard TD. San Jose State responded later in the period, however, when Gray hit senior receiver Hansell Wilson for a 20-yard score.

Bulldogs kicker Kody Kroening (Valley Christian-San Jose) made a 39-yard field goal to narrow SJSU’s lead to 21-10 before halftime.

Ervin got his third touchdown of the game on a 30-yard burst up the middle in the third quarter. Fresno State answered on its next possession, with freshman receiver KeeSean Johnson (Palo Alto High) hauling in a 29-yard TD pass from Childress.

The Bulldogs pulled within 28-23 later in the quarter after recovering a muffed snap by San Jose State punter Michael Carrizosa, but Gray threw touchdown passes on each of the Spartans’ next two possessions to keep Fresno State at bay.

Senior cornerback Jimmy Pruitt returned an interception 27 yards for a TD in the fourth quarter to cap the scoring for SJSU.

Carrizosa, who entered the game leading the nation in individual punting, had a light workload before the third quarter Saturday night. SJSU didn’t use his services once in the first half. When the sophomore finally did enter the game, however, the results were disastrous. Carrizosa mishandled a snap deep in SJSU territory and Fresno State recovered, setting up a short touchdown drive that pulled the Bulldogs within five points at 28-23. It was the second straight game in which a bobbled snap by Carrizosa set up an opponent’s TD. It happened with the game tied at 21 against Oregon State, and the ensuing touchdown put the Beavers ahead to stay.

After struggling in losses to Air Force and Oregon State, San Jose State’s run defense showed tremendous improvement against Fresno State, limiting the Bulldogs to a paltry yards on the ground. In fact, SJSU’s defense as a whole played well — its secondary in particular. Cornerback Andre Chachere and safety Maurice McKnight, both sophomores, each had tackles for loss. One of Chachere’s was a sack.