Not sure which country you're talking about exactly, but don't countries in Scandinavia benefit from large resources of oil and natural gaz in the North Sea? That sure eases welfare.
I'm a French expat living in Denmark, which is definitely not blessed by large amounts of resources of any kind. But you could take Germany as another example of a country who is not about to run out of other people's money any time soon.
Or to take examples in a different way: Spain and Ireland's issues were mostly caused by a housing bubble.
« Denmark has considerably large deposits of oil and natural gas in the North Sea and ranks as number 32 in the world among net exporters of crude oil[101] and was producing 259,980 barrels of crude oil a day in 2009 »
It seems I have underestimated the Danish oil reserves. However, oil export is a small fraction of its economy. I haven't been able to find an accurate figure, but according to Danmark statistik [1], it was about 8.17% of Danish exports in April 2014, which is very far from making Denmark into an oil-based economy like Norway is.