*TSX edges up 0.06 percent to 13,340.83
* Three biggest sectors keep index in positive territory (Updates to close)
TORONTO, July 20 (Reuters) - Toronto's main stock market index closed slightly higher on Wednesday as weakness in industrials was offset by stronger energy and banking shares.
The index's three biggest groups -- energy, financials, and materials -- all advanced, and their mild gains were enough to prop up the index for a second straight daily rise.
All three groups were represented among the most heavily weighted climbers. Royal Bank of Canada RY.TO, up 0.94 percent at C$53.56, led all influential gainers. Barrick Gold ABX.TO rose 1.08 percent to C$46.71, followed by Encana ECA.TO, which added 1.29 percent to C$29.83.
The Toronto Stock Exchange's S&P/TSX composite index .GSPTSE closed up 7.91 points, or 0.06 percent, at 13,340.83. Six of its 10 main sectors were lower, led by a 1 percent decline in the industrials group, while telecoms slid 0.94 percent. The infotech group was unchanged on the day.
"We've been accustomed to markets that can change their mind in a hurry," said Fred Ketchen, director of equity trading at ScotiaMcLeod. He said sector rotation was one reason behind the sharp declines in some sectors.
The political battle over increasing the U.S. debt ceiling as well as the worries about sovereign debt problems in Europe have been a drag on stocks.
European Union leaders must find a convincing solution to Greece's debt crisis at a summit on Thursday or the global economy will pay the price, the head of the European Commission said in an unusually somber warning. [ID:nL6E7IK1QO]
($1=$0.95 Canadian) (Reporting by Ka Yan Ng; editing by Peter Galloway)