* TSX rises 29.32 points, or 0.23 percent, to 12,733.84 * Seven of the 10 main index sectors advance * Suncor, Enbridge have biggest positive influence on index By John Tilak TORONTO, Aug 16 (Reuters) - Canada's main stock index advanced to its highest level in more than three weeks on Friday as supply worries drove gains in the price of oil and in the shares of energy companies, offsetting declines in mining stocks. The Toronto stock market index, which has managed to outperform the S&P 500 in August to date, was on track for a weekly gain. A report on Friday showed U.S. consumers, bracing for higher interest rates and slightly slower economic growth, were a bit less optimistic in August as sentiment retreated from last month's six-year high. Investors bracing for the U.S. Federal Reserve to begin tightening monetary policy were dissecting every piece of economic data to try to figure out when the Fed will start to move. "The initiation of (Fed) tapering is the worst-kept secret in town. The question is when," said Irwin Michael, portfolio manager at ABC Funds. Investors should look at the stimulus pullback as "a positive thing, that the economy has nursed itself back from the 2008-2009 lows," he added. The Toronto Stock Exchange's S&P/TSX composite index was up 29.32 points, or 0.23 percent, at 12,733.84, after rising as high as 12,740.70, its highest level since July 24. Seven of the 10 main sectors on the index were higher. Oil and gas shares climbed 0.6 percent as oil prices rose on concerns that violence in Egypt could affect the Suez Canal, a conduit for up to 3 million barrels per day of oil. In the group, Suncor Energy Inc rose 1.5 percent to C$35.50, and Enbridge Inc advanced 1.1 percent to C$43.82. The two stocks had the biggest positive influence on the index. Financials, the index's most heavily weighted sector, gained 0.2 percent. Royal Bank of Canada, the country's biggest lender, added 0.3 percent to C$64.02. But the materials sector, which includes mining stocks, slipped 1.4 percent. Barrick Gold Corp lost 2.3 percent to C$19.97, and fertilizer producer Potash Corp fell 1.9 percent to C$31.58.