The Edmonton Oilers won the NHL draft lottery and the right to select Erie Otters star center Connor McDavid with the top pick.
The Oilers bucked the odds Saturday night after finishing 28th in the NHL standings. They had just an 11.5 percent chance to win the lottery.
The Sabres will pick second and the chance to land a highly touted consolation prize in Boston University freshman center Jack Eichel. Arizona will pick third.
Both centers are described as having "once-in-a-generation" type of talent by NHL scouts and executives.
McDavid was first and Eichel second in the final rankings of North American skaters issued by the NHL's Central Scouting bureau 10 days ago. And that is the order in which they are expected to be selected at the draft in Sunrise, Florida, on June 26.
The lottery was held in Toronto.
This marked the second straight year Buffalo lost the lottery, after Florida won last year.
While the Sabres keep losing in the lottery, the Oilers keep winning.
This marks fourth time in six years the Oilers will be picking first.
Despite all that top-end talent, the Oilers missed the playoffs for a ninth straight season this year, a drought that dates to 2006, when they lost in the Stanley Cup finals to Carolina.
"It's an amazing organization and a true honor to be going there," McDavid said.
The last-place-finishing team has gone on to win the first pick six times in the 20 years the lottery was held. Edmonton in 2010 was the last to do so, capping a three-year run of 30th-place teams landing the No. 1 pick.
The largest jump in the draft rankings happened twice. In 2000, the Islanders went from fifth to first and selected goalie Rick DiPietro after winning the lottery. Chicago made the same jump in 2007, and chose Patrick Kane.
At 6 feet and 195 pounds, McDavid is regarded as a more talented and creative play-maker than Eichel, who brings a more physical element to his game with a 6-2, 200-pound frame.
Central Scouting director Dan Marr called McDavid "a craftsman with the puck."
"His hockey sense with his vision, his anticipation, his sense of timing and the ability to do those things at top-end speed: You're looking at the best skilled player in the draft."
McDavid had 44 goals and 120 points in just 47 games with Erie this season. He still finished third in the Ontario Hockey League scoring race despite missing a few weeks with a hand injury, and another few weeks to help Canada win the world junior tournament in January. He has added 11 goals and 23 points in nine playoff games -- including a five-goal outing April 10.
Erie has advanced to face Sault Ste. Marie in the OHL semifinals, which open Thursday.
Eichel showed no signs of youth playing against older players during his freshman season at Boston University. He led the nation with 71 points (26 goals, 45 assists) in becoming college hockey's second freshman to win the Hobey Baker award on April 10.
The only other freshman to do it was former NHL star forward Paul Kariya in 1993 with Maine.
"He is proving to be such an amazing game-breaker," Marr said of Eichel. "He's relentless and driven on the play and has the smarts, speed and skills to deliver a needed scoring drive to tie up or win a game."
Eichel missed an opportunity to win an NCAA title last weekend, when Boston University lost 4-3 to Providence.
The Sabres finished last for a second consecutive season as part of a long-range process to rebuild from scratch. They've spent the past three seasons unloading high-priced veterans -- a group that included goalie Ryan Miller and star forward Thomas Vanek -- in exchange for stockpiling draft picks.
Sabres fans spent much of the season rooting for their team to finish last in order to have a guaranteed shot at either McDavid or Eichel.
The Sabres also made every attempt to make McDavid and Eichel feel comfortable with Buffalo.
Eichel played in Buffalo in September as part of USA Hockey's All-American Prospects game. A month later, some 12,000 fans turned out at the Sabres home arena for an Ontario Hockey League regular season game between Erie and Niagara.
And they'll both be back in Buffalo next month, when the city will host the NHL's annual pre-draft rookie combine.