For more than two years, patrons at a downtown Calgary eatery have enjoyed a 20 per cent discount on every bottle of wine on weekdays.

The Barcelona Tavern expected the promotion, dubbed "Time to Wine about Oil," to last only a few months at the beginning of 2015. The price of oil was tumbling and the restaurant wanted to attract recession-weary Albertans by promising cheaper wine until the price of crude rebounded past $70 US a barrel.

Twenty-seven months later, however, oil prices remain south of $50 and the promotion remains in place. The owners of the tavern, like nearly every other Albertan, never expected the downturn in the oilpatch to last this long.

Nathan Jokela shows off his restaurant's promotion 'Time to Wine About Oil,' meant to help draw in customers during the downturn. (Colleen Underwood/CBC )

It's also fair to suspect that neither did the federal government, though you can be sure the price of oil has been weighing on Finance Minister Bill Morneau as he crafted this year's budget, which will be unveiled Wednesday.

For several years Canada's biggest export was oil. Only since the price collapse has it fallen to second, behind vehicles and auto parts.

The fall economic update described the commodity price collapse as having a "profound effect on the Canadian economy." Over the last few years, the decline has cost the Canadian economy $112 billion, which works out to $6,200 for every working person.

If you want to know how the oil downturn can cause havoc on a government's budget, just look to Alberta, Saskatchewan and Newfoundland and Labrador. Just last week Alberta announced another budget with a $10-billion deficit.

Oil production is increasing in the Alberta oilsands and the rest of Canada, but prices remain below $50 US per barrel. (Kyle Bakx/CBC)

Wednesday's federal budget would be easier for Morneau if oil prices were higher. The plunge in oil prices that began in late 2014 from more than $100 US a barrel has had several effects beyond the price of a bottle of Sauvignon Blanc at a Calgary restaurant.

Tens of thousands of people have lost their jobs, investment in the oilpatch has plunged by tens of billions of dollars and the loonie has lost significant value because of the oil downturn.

Revenue down, but expenses too

The federal government does not have a direct tie to oil prices, as there is no line item in the budget for royalty revenue, like there is in Alberta. However, the federal budget is still affected in several ways.

"As companies struggle and make less money, there is a hit to the federal government's corporate income taxes. As people lose their jobs and as wages decrease, there is a hit on personal income taxes," said Trevor McLeod, a natural resources analyst with the Canada West Foundation, a Calgary-based think-tank.

Many expenses and revenues change with a swing in oil prices, according to the University of Calgary economics professor. 1:06 At the same time, the federal government's expenses increased as it extended employment insurance benefits to the areas of the country affected by the oil downturn. Ottawa pledged $19 million to help Service Canada process the increased EI claims and a further $73 million to improve access to EI call centres.

If oil were to recover and companies began spending more money and hiring more workers, the federal government wouldn't have to spend as much on social services such as employment insurance.

On the flip side, some expenses will be lower. Energy and fuel costs are down, while some transfers that are explicitly tied to the size of the economy or the rate of inflation are affected. With low oil, those transfer payments will decrease.

Weigh it all out and the oil price collapse is leaving a hole in the federal budget.

From $50 to $80

If oil increased from its current level of $50 US a barrel to $80 US, the difference to federal coffers would be about an additional $5 billion. Considering the budget is about $300 billion, says economist Trevor Tombe with the University of Calgary, it's not a major shift for the federal government.

"It's certainly not as big of a deal for the federal government as it is for Alberta," said Tombe, who suggests the oil-reliant province needs structural change.

The federal government is currently running a $25-billion deficit, so at the very least an extra $5 billion would help, even if Ottawa remains in the red.

Outside of the federal budget, researchers say the oilpatch downturn is hurting just about every province in the country.

Many global factors impact oil prices, according to the natural resources analyst with the Canada West Foundation 1:16

"We find that almost every province (with the exception of New Brunswick) experiences a negative welfare impact," wrote Jared Carbone at the Colorado School of Mines and Kenneth McKenzie at the University of Calgary in a recent report.

"While the manufacturing sector benefits from the reduction in energy prices and increased international exports due to a depreciation of the Canadian dollar, on balance Ontarians suffer from the higher international prices of consumer goods and from the lower demand for the goods that they export to other parts of Canada, most particularly the oil producing regions."

Volatile oil prices

Most forecasts expect oil prices to gradually rise in the coming years, but the commodity's price is volatile and tough for experts to predict. The federal government built a contingency fund into its last budget in case its forecast for oil was wildly inaccurate.

"You look at global energy demand and everyone largely agrees that that is going up," said McLeod with the Canada West Foundation.

"But there is so much discrepancy with oil demand forecasts. Many think it is going up and will continue to rise through 2040, but there are projections having it dropping off a cliff before 2040. It's really hard given the range of projections."

The only way for the financial effects of the downturn to go away is for prices to bounce back, which at this point is uncertain.