* TSX rises 56.41 points, or 0.46 percent, to 12,196.74 * Nine of the 10 main sectors advance * Royal Bank of Canada up 0.89 pct on earnings * RIM up 7 percent after Goldman Sachs upgrade By John Tilak TORONTO, Nov 29 (Reuters) - Canada's main stock index hit its highest level of the week on Thursday, led higher by Royal Bank of Canada after strong quarterly earnings and further boosted by a rally in Research in Motion Ltd after an influential upgrade. The market was also supported by optimism that a deal would be reached to avert the U.S. fiscal crisis and positive housing data from the country, Canada's biggest trading partner. The combination of healthy Canadian bank earnings and some encouraging global economic data could help the Toronto index extend gains further into the end of the year, said John Kinsey, portfolio manager at Caldwell Securities Ltd. "We're getting into the Santa Claus rally. We are going to have a good market here for the next two weeks," he said. The Toronto Stock Exchange's S&P/TSX composite index was up 56.41 points, or 0.46 percent, at 12,196.74. Nine of the 10 main sectors on the index were trading higher. Energy stocks, up 1 percent, played the biggest role of any sector in leading the market higher, helped by a rise in oil prices. Canadian Natural Resources rose 1.8 percent to C$28.75, and Suncor Energy climbed 1.1 percent to C$32.96. Financials were up 0.6 percent, with Royal Bank of Canada rising 0.7 percent to C$58.77. Canada's biggest bank reported a 22 percent jump in fourth-quarter profit on rising fixed income trading revenue and steady loan growth. Shares of other banks rose on optimism about the strength of the sector, and some of them will be reporting quarterly results next week. Toronto Dominion Bank was up 0.8 percent at C$82.18. TD and RBC played the biggest role of any two stocks in leading the market higher. Research in Motion, which surged more than 12 percent in early trading, was up 7 percent at C$11.73 after Goldman Sachs upgraded the stock ahead of the release of its BlackBerry 10 device lineup. "RIM has had a nice rally. It could be setting us up for a very big disappointment with the new BlackBerry 10. Or it may be a turnaround story," Kinsey said.