NEW YORK - Wall Street was mixed yesterday, recovering from an early loss as investors shrugged off disappointing housing and consumer confidence data to focus on stronger-than-expected quarterly earnings. The Dow Jones industrials set a new trading high, and resumed their trek toward 13,000.

The market picked up momentum in midafternoon. Investors seemed to lose some of the caution they had adopted after the National Association of Realtors reported that the decline in sales of existing homes in March was the biggest since January 1989. Also, the Conference Board reported consumer confidence fell more than expected in April because of higher gas prices and broader economic concerns.

Robust first-quarter earnings reports have been driving the market higher in the last week, allowing the Dow to approach 13,000, and more upbeat results cheered the market yesterday: from U.S. military contractor Lockheed Martin Corp., Dow industrials companies AT&T Inc. and DuPont Co., and chipmaker Texas Instruments Inc.

"A general optimistic tone related to better-than-expected earnings is what's moving it," said Richard E. Cripps, chief market strategist for Stifel Nicolaus, a broker based in St. Louis. However, "it's not a market that's necessarily very broad in its advance."

He pointed out that the Dow's strong afternoon gains had been driven by only a few companies, notably International Business Machines Corp. and Honeywell International Inc., which both made dividend announcements. Also, there were much smaller moves in the broader Standard & Poor's 500 and Nasdaq composite indexes - which have risen by greater percentages than the Dow this year.

The Dow rose 34.54, or 0.27 percent, to 12,953.94. The index set a new intraday high of 12,989.86.

The S&P 500 index was down 0.52, or 0.04 percent, to 1,480.41, and the Nasdaq rose 0.87, or 0.03 percent, to 2,524.54.

Investors weren't buying with abandon: Declining issues outnumbered advancers by about 3-2 on the New York Stock Exchange, where consolidated volume came to 3.11 billion shares, up from Monday's 2.56 billion.

The dollar fell against other major currencies, with the euro close to its record high of $1.3667. Gold prices also fell.

Oil prices declined, with a barrel of light sweet crude down $1.30 at $64.59 on the New York Mercantile Exchange. There have been continued concerns about violence in Nigeria, a key oil producer, and the size of inventories of oil and gasoline in the United States.

In earnings news, AT&T reported profit doubled during the first quarter to beat Wall Street projections. However, shares fell 67 cents to $39.10 as growth in its wireless business lagged.