Updated from 4:05 p.m.

Stocks retreated for a second day Wednesday, as weak economic data and mixed corporate news gave investors an excuse to sell.

The Dow Jones Industrial Average ended down 31 points, or 0.3%, at 8647, while the Nasdaq fell almost 5 points, or 0.3%, to 1534. The S&P 500 lost 3 points, or 0.3%, to 9439.

Although banks, retailers and semiconductors pulled back, networkers rose after Salomon Smith Barney raised its rating on the group. Biotechs, oil and drug stocks also inched higher.

"The market's been off a bit today, slipping on a weaker-than-expected April retail sales report, disappointing results from Applied Materials and probably some more profit taking," said Paul McManus, director of fundamental research at Independence Investments. "That it wasn't worse is probably another good sign that the market's climb has staying power."

While bulls tried to put a positive spin on the day's economic data, the bears won out Wednesday. Retail sales unexpectedly fell 0.1% in April, below economists' estimates for a 0.4% rise and down from a 2.3% rise in the prior month. Still, some economists noted that retail sales would have been up 0.4% excluding a big drop in gasoline sales. Retail sales fell 0.9% excluding autos.

"Our second-quarter GDP estimate of 1.8% was already at the low end of consensus, and this data could cause us to lower it," said Merrill Lynch economist David Rosenberg.

A decline in import prices was also somewhat disconcerting because it showed that the weakness in the dollar might not be helping to increase inflation. The Fed said last week it is more concerned about deflation now than a big rise in prices. Import prices fell 2.7% last month to a 14-year low, although the decline mostly reflected falling oil prices, according to the Labor Department. "Investors have seemed to write off April's generally weak economic reports," McManus said. "They won't be as forgiving if May and June come in weak too."

Other ominous developments Wednesday included a rally in Treasuries, which pushed the yield on the 10-year note down to 3.51%, the lowest yield since 1958. Crude oil prices for June delivery rose 67 cents to $29.17 in New York, the highest closing price since April 22. Meanwhile, the dollar continued to rally against the euro but was lower against the yen.

On the corporate news front, chip-equipment maker Applied Materials ( AMAT) disappointed investors by reporting a loss in its fiscal second quarter and predicting weaker-than-expected sales for the current period. Shares fell 4% to $14.97.

Meanwhile, retailer Abercrombie & Fitch ( ANF) said second-quarter earnings will miss analysts' estimates. Federated Department Stores ( FD) said net income fell 48% in the first quarter, although it beat expectations because of lower store-closing costs. Abercrombie fell 6% to $27.98, and Federated slid 2% to $31.70.

Dreyer's Grand Ice Cream ( DRYR) jumped 3% to $75.82 after federal antitrust regulators said they would drop their opposition to Nestle's takeover of the firm if both companies agree to some concessions, according to The Wall Street Journal.

In the networking space, Juniper ( JNPR) climbed 4% to $13.01 after Salomon Smith Barney upgraded the stock to outperform from in line, saying it expects "solid sequential growth" despite the firm's "overly cautious" guidance. Salomon also raised its rating on Enterasys ( ETS) and upgraded the entire sector to market weight from underweight.

Computer Sciences ( CSC), which provides computer services, posted a rise in its fiscal fourth-quarter profit and predicted current-quarter and full-year sales will surpass Wall Street estimates. Shares rose 9.6% to $37.30.

Shares of Millennium Pharmaceuticals ( MLNM) gained 15% to $14.39 on Instinet after the Food and Drug Administration approved on Tuesday the company's cancer drug Velcade.

Overseas markets were mixed, with London's FTSE 100 down 0.6% at 3975 and Germany's Xetra DAX up 0.3% at 2919. In Asia, Japan's Nikkei closed 0.7% higher at 8244, while Hong Kong's Hang Seng lost 0.2% to 9103.

On Tuesday, the Dow ended 0.5% lower at 8679. The S&P 500 fell 0.3% to 942, while the Nasdaq shed 0.1% to 1539.

If you liked this article you might like

Coming Week: Earnings Flood

Coming Week: Earnings Flood

Don't Write Off Inflation Threat

Don't Write Off Inflation Threat

No Quick Fix for Trade Gap

No Quick Fix for Trade Gap

Merrill's Doll Sees Stocks 'Muddling Through'

Merrill's Doll Sees Stocks 'Muddling Through'

Downhill From Profit Peak

Downhill From Profit Peak