CALGARY, Alberta (AP) -- David Perron scored the go-ahead goal midway through the third period and the Edmonton Oilers rallied from a 2-0 third-period deficit to win 4-2 over the Calgary Flames on Saturday.
Perron had the puck behind the Flames net and banked it off the back of goaltender Reto Berra at 10:23. The goal came just over two minutes after another odd goal for the Oilers tied it.
Sam Gagner's shot deflected off Flames defenseman Dennis Wideman and fluttered high in the air. While Berra couldn't find it, Ales Hemsky batted in from out of midair for his first goal in 12 games.
Edmonton started its comeback at 3:41 when Jordan Eberle took a drop pass from Taylor Hall and ripped a shot over the blocker of Berra.
The three-goal barrage in a span of 6:42 came on four shots.
Boyd Gordon added an empty-net goal in the final minute.
Edmonton, which began the night in last place in the NHL, snapped a five-game losing streak and won for just the second time in its past 12 games (2-9-1).
Sean Monahan and Wideman scored for Calgary. The Flames are winless in their past six, and are 0-4-1 in their past five games at home.
The Flames finished 0-2-1 on a three-game homestand. After a one-game trip to Winnipeg on Monday, Calgary begins another three-game homestand.
The first of five meetings between the provincial rivals featured the teams ranked 13th and 14th in the Western Conference.
The Flames remain three points up on Oilers.
Devan Dubnyk had a huge game for the Oilers making 33 saves. That comes on the same night that newly signed Ilya Bryzgalov picked up a win for Edmonton's AHL affiliate, allowing only one goal in his second conditioning start, in Oklahoma City's 4-1 victory over Abbotsford.
Calgary took a 2-0 lead at 17:08 of the second period on a shot off the stick of Wideman.
With the Flames applying pressure, the puck squirted back to Wideman who leaned into a slap shot that went top corner on Dubnyk, who never saw it as he was screened on the play by Lee Stempniak.
The Flames have struggled early in games of late having given up the first goal in seven of the past eight games and being outscored 11-1 in the first period during that span.
However, they went on the attack early against the Oilers, racking up a 5-0 edge in shots just over four minutes into the game.
The Flames took a 1-0 lead on a terrific play by Jiri Hudler.
Hustling after Ryan Nugent-Hopkins on the backcheck, he knocked the puck away from him where it was picked up by Monahan, who headed in the other direction.
Monahan gained the Oilers zone, dropped the puck to Hudler who zipped it right back to Monahan and he snapped a puck past Dubnyk on the blocker side.
It was the first goal in seven games for Calgary's 2013 first-round draft pick and just his second in the past 12 after he started the season with six in his first eight.
It also marked the first time Calgary held a lead after the first period in three weeks. In the previous eight games, the Flames had been outscored 11-1 in the opening 20 minutes.
The game began with a throwback to the old days of the Battle of Alberta as heavyweights Brian McGrattan and Luke Gazdic squared off in a lengthy fight that fired up the crowd.
Notes: Healthy scratches for Calgary were RW Tim Jackman and D Sean O'Brien. ... LW Ryan Jones was not in the lineup for Edmonton. ... After several years of Calgary domination, Edmonton has won five of the past seven games between the two teams. ... Flames LW TJ Galiardi hasn't scored in his past 18 games. Also slumping is D TJ Brodie, who has no points in his past eight games. ... For Edmonton, Nugent-Hopkins has one goal in his past 13 games.
Copyright 2013 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.