In a game filled with late inning maneuvering and pitching changes, the Cardinals (19-15) prevailed behind the pitching of Larry Jackson, Marshall Bridges and Bob Gibson (W, 2-2). St. Louis stayed in second place and moved within two games of the San Francisco Giants, who lost to Milwaukee.
The Pirates (16-18) have lost three in a row.
In the tenth, Grammas singled with one out. Pinch-hitter Wally Shannon flied out, but Don Blasingame kept the inning alive with a hard single to right that moved Grammas to second base. Cimoli then delivered a bounding ball up the middle.
Bob Porterfield (2-1) took the loss for Pittsburgh, whose only run was unearned in the sixth, courtesy of two Cardinals errors in the inning.