Stocks seesawed on Wednesday as disappointing quarterly results from top banks sparked caution over the health of financials, though sentiment rose after a robust earnings report from Apple Inc .

The market was weighed down by a third-consecutive quarterly loss at Morgan Stanley and as rising credit losses at Wells Fargo & Co and several regional banks dented recent optimism about the financial sector's recovery.

Morgan Stanley shares fell 1.3 percent to $27.20 while Wells Fargo dropped 6 percent to $23.83. Financials <.GSPF> were the worst-performing sector in the S&P 500, down 1.5 percent.

The increase in bad loans at Wells Fargo has broader implications for the banking sector, said Steve Goldman, market strategist at Weeden & Co in Greenwich, Connecticut.

On top of that, technicals say the market is overbought, he said, referring to the recent results-driven market run-up.

The Dow Jones industrial average <.DJI> edged up 7.18 points, or 0.08 percent, at 8,923.12. The Standard & Poor's 500 Index <.SPX> gained 0.75 points, or 0.09 percent, at 955.43. The Nasdaq Composite Index <.IXIC> rose 6.46 points, or 0.34 percent, at 1,922.66.

The Nasdaq ended Tuesday on a 10-day winning streak, its longest in 12 years.

Apple posted late on Tuesday quarterly profits that beat forecasts, helped by robust sales of Mac computers and iPhones and higher-than-expected gross margins, sending its shares up more than 4 percent to $158. For details

Also buoying the Nasdaq, Starbucks Corp jumped 14 percent to $16.75 as the coffee chain's results topped expectations.

Boeing Co shares were mostly flat after it posted a 17 percent increase in quarterly profit, topping forecasts, but the plane maker did not say when its long-awaited 787 Dreamliner would be ready to fly.

Drugmaker Pfizer Inc

said its second-quarter earnings fell 19 percent, hurt by a stronger U.S. dollar, but raised its full-year forecast for earnings, excluding items, and for revenue. Its shares jumped 3.5 percent to $16.25.

Regional bank KeyCorp posted a wider-than-expected loss, hurt by bad loans, and its shares fell 1 percent.

Federal Reserve Chairman Ben Bernanke reiterated in testimony to the Senate Banking Committee that the U.S. economic outlook is improving but that supportive policies would be necessary for a while to prevent rising joblessness from sapping the recovery.

(Additional reporting by Chuck Mikolajczak; Editing by Padraic Cassidy