(Updates with official closing numbers, adds detail)
TORONTO, Feb 20 (Reuters) - The Toronto Stock Exchange's main index charged higher on Wednesday, shrugging off early losses, as resource shares were boosted by new highs from oil and gold prices.
The energy and materials sectors, which combined make up about 40 percent of the index, gained 0.9 percent and 1.2 percent respectively, taking their cue from underlying commodity prices.
Oil hurtled to a record $101.31 a barrel, spurred by concerns over supply from OPEC. Crude closed at $100.74, the top settlement on record.
Gold prices also followed oil's momentum to hit a high of $943.20 an ounce before stepping back to $934.80. The gold-producers subindex rose 1.2 percent, with Centerra Gold (CG.TO) gaining 29 Canadian cents, or 2.1 percent, to C$14.04. Also in the resources space, Agrium Inc (AGU.TO) climbed C$2.43, or 3.5 percent, to C$71.43.
The S&P/TSX composite index .GSPTSE closed up 103.95 points, or 0.77 percent, at 13,551.69 with seven of its 10 main groups in positive territory.
Canadian Pacific Railway Ltd (CP.TO)(CP.N) also helped pull the index higher after it said it will appeal a grain rate ruling by the Canadian Transportation Agency that could take a bite out of its earnings for 2008.
CP rose C$1.57, or 2.2 percent, to C$73.26. Canadian National Railway Co (CNR.TO), which also said it will appeal the decision, was up 68 Canadian cents, or 1.3 percent, at C$53.15.
Shares of TransAlta Corp (TA.TO) added 76 Canadian cents, or 2.2 percent, to C$35.41 after it said it has sold its Mexican power plants for $303.5 million.
On the downside, home improvement retailer Rona Inc RON.TO was among the biggest drags on the benchmark, shedding 94 Canadian cents, or 5.8 percent, to C$15.41 after reporting a drop in profit.
$1=$1.01 Canadian Reporting by Leah Schnurr; Editing by Peter Galloway