Unbeaten Joaquin Andujar pitched a five-hitter for his third victory this season as the St. Louis Cardinals beat Dwight Gooden and the visiting New York Mets, 5-1, yesterday.

Andujar, who has a 12-5 career record against the Mets, struck out three, walked one and retired 14 consecutive batters in one stretch. Gooden (2-1) surrendered four hits in seven innings.

With the game scoreless in the St. Louis seventh, Tom Herr walked and Jack Clark and Andy Van Slyke (RBI) singled. After Terry Pendleton's sacrifice bunt, Mike Lavalliere hit a sacrifice fly. The runs ended Gooden's streak of scoreless innings at 23.

Andujar made three fine defensive plays. Cardinals Manager Whitey Herzog said, "I told him he's got the greatest shortstop (Ozzie Smith) that's ever played -- let him go after the ball. (Andujar) was diving all around. He said, 'I don't trust him.' "

The Mets scored in the ninth on doubles by Keith Hernandez and Danny Heep, who had started in left field in place of George Foster.

Before the game, Foster strained knee ligaments while running. Foster, 36, will return with the team to New York, where he was to be examined by the Mets physician today.