Look west from the office towers of the energy companies that dominate Calgary, and the view is spectacular: Rolling prairies rise to tree-clad foothills, with the jagged, snow-capped peaks of the Rockies on the horizon.

Looking down, however, is more unsettling. The city is dotted with motionless construction cranes poised over the pits of abandoned projects. A five-year energy boom here in the administrative heart of Canada's oil patch and in the tar sands far to the north has ended.

The only debate is how painful and persistent the bust will be -- not just for the biggest city in Canada's richest province, Alberta, but for the whole country.

Alberta, which produces two-thirds of Canada's oil and gas, has been here before. The wrenching oil slump of the 1980s still looms large in the public consciousness. Companies fled the province and thousands abandoned homes that they could no longer afford.

"The situation is much different this time," insists the energy minister, Mel Knight, whose Progressive Conservative Party has ruled the province since 1971. But not all of the differences are positive ones.

Knight believes that continuing demand from places such as China and India will mean that oil, and thus his province's economy, will recover faster this time. However, two decades ago there was nothing like the current global credit crunch.

Also, Alberta extracts 60 percent of its crude oil from its tar sands (those in the business think "oil sands" sounds nicer), a much bigger proportion than in the 1980s, and concern about the environment and carbon-based fuels is far stronger now.

When news broke in December that construction had briefly halted on the Bow, the showpiece headquarters of EnCana, the country's largest independent energy firm, it sent shockwaves across Calgary. The 58-story tower designed by Lord Foster, a British architect, is a symbol of Alberta's new role as Canada's economic engine and a poke in the eye for Toronto, the traditional corporate headquarters.

The Bow's owner says it still needs $327 million of financing to finish the job. Up north in the tar sands, many projects are being postponed, as the credit crunch adds to the woes caused by low oil prices and high labor and material costs.

Petro-Canada and its partners put the giant Fort Hills project on hold after the estimated costs rose to around $19.8 billion from $11.1 billion in just more than a year.

Extracting oil from the sands took off in the late 1990s, boosted by technological advances that greatly reduced costs. Sitting on the equivalent of 173 billion barrels of crude, the provincial government dreamed of making Alberta a new Saudi Arabia (with moose instead of camels).

Although some, such as Peter Lougheed, a former premier, called for "orderly" development, a wild rush ensued, causing province-wide labor shortages. Even servers at fast-food restaurants had to be lured with promises of iPods or other inducements.

Now, though, employment is slumping: Steve Vetter, a manager at a firm that serves the gas industry, says it recently had 50 applicants for one job; two years ago it would have been lucky to get any.

Extracting oil from tar sands causes more carbon emissions than traditional drilling. At some projects, leaks of toxic material have polluted waterways. So even if the credit crunch eases and the oil price steadies, Canada's tar sands may face tougher scrutiny from their main customer.

The United States has hitherto been an enthusiastic buyer, but the administration of President Obama -- packed with environmentalist hawks -- may prove much less so, especially as the Democrats also control Congress.

Democratic Rep. Henry Waxman of California -- a green crusader -- is the chairman of the House Energy Committee. He wrote part of an energy bill passed in 2007 that seemed to ban government agencies from buying oil produced from the tar sands.

It will be a further damper on investment in Alberta if the Obama administration enforces the ban. Canada Prime Minister Stephen Harper, who soon will meet with Obama, said recently that the tar sands would be one of the stickier subjects on their agenda.

On top of the oil bust, Canada's other commodity exports -- such as lumber -- are also suffering collapsing demand. After years of good growth, the economy will shrink this year. Harper said it will take as long as five years of "big, comprehensive" government stimulus to dig it out of the deep, black hole it is in.