Federal Hall’s George Washington statue stands near the flag-covered pillars of the New York Stock Exchange.  (AP Photo/Bebeto Matthews, File)

AP Business Writer

Gains by health care companies led U.S. stock indexes mostly higher Tuesday, pushing the market further into record territory.

The Dow Jones industrial average briefly climbed above the 23,000 mark for the first time, settling just below the milestone. Slight gains nudged the Dow and Standard & Poor’s 500 indexes to new highs for the second straight day this week.

Health care companies posted some of the biggest gains following strong earnings from UnitedHealth Group and Johnson & Johnson. News of a plan backed by the White House that would extend federal payments to health insurers also gave the sector a boost. Banks and other financial stocks declined the most. Packaged food and beverage companies were also big laggards.

Trading was mostly listless as investors sized up the latest company earnings news and looked ahead to a full slate of corporate report cards later this week.

“Expectations of ongoing earnings growth are reasonably strong, but there may be a bit of a wait-and-see at this point in time given the run in the equity markets,” said Jason Pride, director of investment strategy at Glenmede.

The S&P 500 index added 1.72 points, or 0.1 percent, to 2,559.36. The Dow picked up 40.48 points, or 0.2 percent, to 22,997.44. The Nasdaq composite slipped 0.35 points, or 0.01 percent, to 6,623.66. The Russell 2000 index of smaller-company stocks fell 5.18 points, or 0.3 percent, to 1,497.50.

More stocks fell than rose on the New York Stock Exchange.

The major stock indexes drifted between small gains and losses for much of the day.

Early on, traders eyed big company earnings news from Goldman Sachs, Morgan Stanley, UnitedHealth Group and Johnson & Johnson, among others.

UnitedHealth, the country’s biggest health insurer, jumped 5.5 percent after reporting earnings that beat analyst estimates. The stock gained $10.69 to $203.89. Johnson & Johnson added 3.4 percent after reporting a strong quarter of its own. Its shares picked up $4.67 to $140.79.

Health insurers, hospitals and other health care companies also rose as two leading lawmakers reached a deal on a plan that would extend federal payments to health insurers that President Donald Trump had blocked last week. Trump said Tuesday afternoon that the White House has been involved in the plan, which he called a “short-term deal.” Biogen gained $8.799, or 2.6 percent, to $344.47, while Anthem added $3.50, or 1.9 percent, to $187.26.

Morgan Stanley posted quarterly results above Wall Street’s expectations. Its shares rose 18 cents, or 0.4 percent, to $49.12.

Traders took a dimmer view of Goldman Sachs’ results. The bank also posted results that beat financial analysts’ estimates, but its trading desks, which are weighted toward bonds, currencies and commodities, struggled during the quarter. Goldman slid $6.32, or 2.6 percent, to $239.09.

Netflix fell 1.6 percent after the streaming video company said its debt and programming costs continue to rise as it gained subscribers last quarter. Its shares lost $3.20 to $199.48.

While only a few companies have reported results so far, earnings are mostly looking good, noted Erik Davidson, chief investment officer for Wells Fargo Private Bank.

“Earnings are growing year-over-year and, most importantly, the (revenue) overall thus far seems to be doing OK,” he said.

Fifty companies are scheduled to report quarterly results this week, the first full week of the third-quarter earnings season. S&P 500 companies are forecast to deliver 3.3 percent earnings growth in the third quarter, according to S&P Global Market Intelligence.

Among the big names due to report earnings this week are American Express, Verizon Communications and General Electric.

Traders also drew encouragement Tuesday from economic data that showed U.S. industrial production rose a solid 0.3 percent last month, as manufacturing of automobiles, home electronics and appliances increased. The gains were limited due to lingering damage from Hurricanes Harvey and Irma.

Separately, a gauge of homebuilders’ confidence rose more than expected this month as builders looked past a recent slowdown in new home sales and the risk of rising labor and materials costs in the wake of the two hurricanes.

Bond prices were little changed. The yield on the 10-year Treasury note held steady at 2.30 percent.

Oil prices closed slightly higher, rebounding after an early slide.

Benchmark U.S. crude gained a penny to settle at $51.88 a barrel on the New York Mercantile Exchange. Brent crude, used to price international oils, rose 6 cents to close at $57.88 a barrel in London.

In other energy trading, wholesale gasoline rose a penny to $1.63 a gallon. Heating oil was little changed at $1.81 a gallon. Natural gas added 2 cents to $2.96 per 1,000 cubic feet.

Gold fell $16.80, or 1.3 percent, to $1,286.20 an ounce. Silver slid 33 cents to $17.04 an ounce. Copper lost 4 cents to $3.20 a pound.

The dollar fell to 112.18 yen from 112.22 yen. The euro weakened to $1.1772 from $1.1792. The pound fell to $1.3191 from $1.3243 after Bank of England Governor Mark Carney warned about the economic impact of Brexit.

Markets overseas were mixed.

In Europe, Germany’s DAX fell 0.1 percent, while France’s CAC 40 was essentially flat. London’s FTSE 100 dipped 0.1 percent.

In Asia, Hong Kong’s Hang Seng was unchanged ahead of a twice-a-decade congress Wednesday by China’s ruling Communist Party. Tokyo’s Nikkei 225 gained 0.4 percent, while Sydney’s S&P-ASX 200 rose 0.7 percent. Seoul’s Kospi added 0.2 percent.