TORONTO -- The Toronto stock market racked up a solid gain for a second consecutive day Wednesday amid positive news from China, while the release of minutes from the latest U.S. Federal Reserve meeting did little to shake the conviction that the Fed is in no rush to end its current economic stimulus.

The S&P/TSX composite index was ahead 50.85 points to 12,534.91 with gains limited by falling gold stocks and retreating bullion prices. The Canadian dollar climbed 0.18 of a cent to 98.58 cents US.

U.S. indexes also rose as the minutes showed that some Federal Reserve officials favoured an end to the bond buying program known as quantitative easing as early as this summer.

Several others thought that if labour conditions improved as expected, the Fed could slow purchases later in the year and stop them by year-end.

However, that meeting took place well before a dismal employment report for March was released last Friday.

The Fed released the minutes early after discovering that some copies had been sent by mistake to Capitol Hill staffers and trade groups on Tuesday.

The Dow Jones industrial average rose 128.78 points to a record high close at 14,802.24, while the Nasdaq composite index climbed 59.4 points to 3,297.25. The S&P 500 index also closed at a record high, up 19.12 points at 1,587.73.

The gains followed customs data that showed China posted an unexpected trade deficit of US$800 million in March as imports rose 14.1 per cent after having grown five per cent in the combined January-February period.

The report suggested Chinese manufacturers and consumers might be buying more, raising hopes for stronger performance from the world's second-biggest economy.

Traders had expected China to post a $15.3-billion surplus for last month.

"While the data has been volatile of late due to holiday distortions, it is clear that the underlying trend in imports is gaining momentum," said Mark Chandler, head of Canadian FIC Strategy at RBC Dominion Securities.

The positive trade data followed the release of lower inflation data Tuesday which gave China some leeway in being able to take further measures to stimulate growth, which came in at 7.9 per cent in the three months ended in December, up from the previous quarter's 7.4 per cent.

"I think China and the emerging markets in general will continue to grow at high single-digit rates," said Paul Vaillancourt, managing director of Fiera Capital Canadian Wealth Management.

"And with inflation numbers coming in confirming that there is no sort of hard landing in China, that is very positive. And I think we will continue to see some strong demand coming from the region. That obviously impacts raw materials like copper and other metals a bit more."

The financial sector led advancers, up 1.43 per cent with Scotiabank (TSX:BNS) up $1.02 to $58.39 and Manulife Financial (TSX:MFC) ahead 39 cents to $14.65.

The telecom sector gained 0.94 per cent while Rogers Communications (TSX:RCI.B) advanced 62 cents to $52.35.

Commodity prices were mixed following initial strong gains in the wake of Tuesday's Chinese inflation data.

The May crude contract on the New York Mercantile Exchange shed early declines to edge up 44 cents to US$94.64 a barrel as data showed crude supplies rose much less than expected last week in the U.S. Inventories grew by 300,000 barrels, against the 1.4 million barrels that economists had expected.

The energy sector rose 1.05 per cent. Canadian Natural Resources (TSX:CNQ) climbed 34 cents to C$32.38.

The gold sector led declines, down about 4.25 per cent as June bullion in New York fell $27.90 to US$1,558.80 an ounce after Goldman Sachs cut its price target for the precious metal. The investment bank said it now expects an average price for gold in 2013 of $1,545, down from a prior forecast of $1,610. It was the second cut for their gold forecast in less than two months. Also, Cyprus said it was selling some gold from its reserves to contribute to the country's bailout. Gold has fallen seven per cent so far this year.l

Iamgold (TSX:IMG) slipped 32 cents to C$6.52 while Goldcorp Inc. (TSX:G) faded 97 cents to $32.

A big contributor to the sector's loss was Barrick Gold (TSX:ABX). Its shares tumbled $2.35 or 8.65 per cent to $24.81 after a Chilean court suspended its Pascua-Lama mine after indigenous communities complained that the project is threatening their water supply and polluting glaciers.

Barrick said Wednesday it was still awaiting formal notification of the injunction halting construction on the Chilean side of the Pascua-Lama mining project and would assess the potential implications when it came.

The base metals sector gave back some of Tuesday's strong 3.25 runup, off 0.53 per cent as May copper dipped two cents to US$3.42 a pound. Taseko Mines (TSX:TKO) slipped five cents to C$2.66 and Teck Resources (TSX:TCK.B) dropped 29 cents to $29.08.

In other news, Porter Airlines confirmed that it has signed a conditional deal to buy 12 of Bombardier's (TSX:BBD.B) new CS100 jets, with options on 18 more. The deal also includes purchase rights for six of Bombardier's Q400s, the planes which make up Porter's current fleet. The total purchase could reach US$2.29 billion if all the options and purchase rights are exercised. Bombardier shares edged up one cent to $4.09 after gaining about two per cent Tuesday when the plane purchase was first reported.

Valeant Pharmaceuticals has settled a patent lawsuit between its Medicis subsidiary and generic giant Actavis Inc. Valeant shares advanced 76 cents to $74.05.

The TSX Venture Exchange slipped 7.03 points to 1,047.74.