Sweden threw a major scare into FYR Macedonia but couldn't spring the upset as the team from the Balkans won 78-73 to clinch first place in Group B.
Fresh off their 95-50 mauling of previously unbeaten Estonia, FYROM moved into the driver seat for a place in the next phase of the additional qualifying tournament for EuroBasket 2007.
As FYROM and Estonia split their two encounters, the tie-breaker used to determined which team finished higher in the standings was goal differential in the games between the two teams.
With Estonia 3-1 and FYROM 2-1 before Saturday's play, all Jovica Arsic's team had to do was prevail in Sweden - a team that had yet to win in the additional qualifying tournament.
For most of three quarters, the Swedes led with Mikael Lindqvist doing much of the damage on offense.
He would have 16 points by the end of the third period.
Sweden's biggest lead was 41-28 with 2:23 to go in the first half.
FRYOM didn't allow them to pull away and with 6:37 to go in the third quarter, they closed the gap to 50-47 after back-to-back three-pointers by Todor Gecevski and Vlado Ilievski.
They eventually pulled level, and at the start of the fourth quarter the contest was tied at 58-58.
FYROM scored the first eight points of the fourth quarter and Sweden's upset bid looked dead.
Yet the Scandinavians had one last run in them and they clawed their way back to 73-70 with 22 seconds remaining when Mats Levin buried a three-pointer.
But Sweden fouled FYROM and Vlado Ilievski sealed the victory at the free throw line by making both attempts.
FYROM advance to Spain for the next phase of the additional qualifying tournament.