J.P. Arencibia's pinch-hit RBI single with the 4, in the middle test of a three-game series.
Gregg then uncorked a wild pitch to plate Johnson, and later in the at-bat Arencibia laced a single to score pinch-runner Chris Woodward and end the game.
The hit made a winner of Jesse Litsch (6-3), who allowed one run on three hits in two relief innings.
Jose Bautista launched a two-run homer and Lawrie added a solo shot for the Jays, who have won four of six and shook off a 2-0 loss in Friday's series opener.
Henderson Alvarez got the start for Toronto, allowing nine hits and three runs over seven innings.
Chris Davis collected two hits and drove in a pair of runs for the Orioles, whose three-game win streak was halted.
Davis' RBI single in the first put the O's on the board, but Toronto moved ahead in the home half when Yunel Escobar worked a leadoff walk and Bautista reached the third deck just to the left of center for his 41st homer of the season.
Kyle Hudson reached second on an Alvarez error to start the second and scored on Angle's two-out base hit, but the Jays moved ahead by a 3-2 count on Lawrie's leadoff homer in the bottom of the frame.
Davis doubled in Guerrero for a 3-3 deadlock in the third, and Baltimore went ahead in the eighth. Robert Andino hit a leadoff double, moved to third on a groundout and scored on a double from Guerrero.
Toronto leads the season series, 11-6, having taken five of eight at Rogers Centre...Escobar left the game in the sixth inning with an injured elbow...Guerrero finished with three hits...Each team left six men on base.