(Updates to midmorning)
*TSX slightly lower in choppy session
*Index gives up earlier gain of 100 points
*Mining and agriculture stocks weigh
TORONTO, July 2 (Reuters) - The Toronto Stock Exchange's main index was slightly lower on Wednesday, retreating from a large gain at the start of the session, as sagging materials offset gains in energy and financial shares.
Mining companies were among the biggest laggards as underlying commodity prices were mixed, while fertilizer companies also dragged. Fording Canadian Coal Trust FDG_u.TO was among the biggest losers, down C$8.88, or 9.1 percent, at C$88.62, as the price of coal fell.
Paul Harris, portfolio manager at Avenue Investment Management, noted that negativity over the global economy and the outlook for the second half of the year was also weighing on the market.
"The economy looks very bad, and numbers continue to be very difficult. I think that's going to be par for the course," said Harris.
The S&P/TSX composite index .GSPTSE was down 31.53 points, or 0.2 percent, at 14,435.50, after climbing as high as 14,584.85 at the start of the session.
The materials sector, home to resource shares, gave up 2.7 percent, while Potash Corp of Saskatchewan (POT.TO) tumbled C$12.81, or 5.4 percent, to C$223.76. Among miners, Teck Cominco TCKb.TO slid C$2.01, or 4.1 percent, to C$47.16.
On the upside, Research In Motion RIM.TO was among the biggest net gainers, rising C$2.91, or 2.4 percent, to C$122.60.
An Indian government official said the telecommunications ministry does not see a security risk from the Canadian company's BlackBerry e-mail service and does not plan to shut the service.
But the broader tech sector gave up 1.2 percent, while Nortel Networks NT.TO was down 42 Canadian cents, or 5 percent, at C$7.93.
The energy sector held onto a 0.3-percent gain, but was off its earlier high, while the price of oil firmed around $141 a barrel. Canadian Natural Resources (CNQ.TO) rose C$2.26, or 2.2 percent, to C$103.10, and Imperial Oil (IMO.TO) put on 70 Canadian cents, or 1.3 percent, to C$56.86.
Financials also trimmed earlier gains, rising 0.9 percent, after Germany's Deutsche Bank (DBKGn.DE) said it expected to make a profit in the second quarter and did not need to raise more capital, improving the sentiment surrounding the outlook for financials.
On Bay Street, Canadian Imperial Bank of Commerce (CM.TO) gained C$1.21, or 2.2 percent, to C$57.31, and Toronto-Dominion Bank (TD.TO) added 99 Canadian cents, or 1.5 percent, to C$65.24. ($1=$1.02 Canadian) (Reporting by Leah Schnurr; Editing by Scott Anderson)