DETROIT — Justin Upton hit a two-run homer off Matt Belisle in the ninth inning, giving Detroit a 12-11 win over the Minnesota Twins on Saturday night after the Tigers wasted a five-run lead and then overcame a five-run deficit.

Detroit had been 0-54 this year when trailing after eight innings and had lost 6 of 7 but rallied to stop the Twins’ six-game winning streak.

After James McCann hit a grand slam in a five-run first inning against Jose Berrios, the Twins tied the score 5-5 in the third, then scored twice in the fourth, once in the fifth and three times in the sixth for an 11-6 lead.

Upton hit a sacrifice fly in the seventh, and McCann hit into a run-scoring forceout in the eighth and scored on Jose Iglesias’ home run against Trevor Hildenberger that cut Detroit’s gap to 11-10.

INDIANS 3, RAYS 0: Jay Bruce drove in his first two runs for Cleveland and Mike Clevinger struck out nine in seven innings as the Indians won at St. Petersburg, Florida.

Bruce, acquired in a trade from the Mets on Wednesday, drove in the first run with a two-out fly ball that dropped for a double between left fielder Corey Dickerson and third baseman Trevor Plouffe in the first inning.

Bruce drove in another run with a single in the fifth after Jose Ramirez’s leadoff double.

ROYALS 5, WHITE SOX 4: Melky Cabrera hit a go-ahead, two-run homer against his former team in the eighth inning, and Kansas City won at Chicago to stop a five-game losing streak.

Cabrera, acquired by Kansas City on July 30, homered with one out off Aaron Bummer (1-3) and drove in Lorenzo Cain, who led off the inning with a walk, and Chris Beck. Cabrera has an eight-game hitting streak.

NATIONAL LEAGUE

MARLINS 4, ROCKIES 3: Giancarlo Stanton continued his power surge with his 41st homer and drove in three runs in Miami’s victory at home.

Stanton went 3 for 4 with two runs scored and is hitting .382 (13 for 34) with eight home runs and 15 RBI in his last nine games. He needs one home run to tie Gary Sheffield for the Marlins’ single-season mark set in 1996.

Stanton has hit 20 home runs in his last 32 games. The last player to accomplish the feat in the same season was the Los Angeles Dodgers’ Shawn Green in 2002, according to STATS LLC.

CARDINALS 6, BRAVES 5: Randal Grichuk and Paul DeJong homered, and host St. Louis stretched its winning streak to eight games.

Carlos Martinez (9-9) tossed six solid innings and also drove in a run for the Cardinals.

Brandon Phillips homered for Atlanta, which dropped its fifth straight.

The eight-game run is the longest for St. Louis since the Cardinals won eight straight from April 28-May 5, 2015.

INTERLEAGUE

BLUE JAYS 7, PIRATES 2: Chris Rowley pitched 51/3 innings to win his major league debut, Jose Bautista scored two runs and Toronto won at home.

A former first lieutenant in the United States Army, and the first graduate of the United States Military Academy in West Point, New York, to reach the majors, Rowley missed all of the 2014 and 2015 minor league seasons while on active service, including a stint in Bulgaria. The right-hander allowed one run on five hits.