Energy companies were leading stocks higher in midday trading as the price of crude oil climbed, keeping major indexes near record highs.

Transocean, a rig operator, climbed 3.8 percent Monday. Marathon Oil rose 3.7 percent.

advertisement | advertise on newsday

Cybersecurity company Symantec was up 4 percent as last week’s global cyberattack spread.

The Standard & Poor’s 500 index rose 10 points, or 0.4 percent, to 2,401.

The Dow Jones industrial average gained 74 points, or 0.4 percent, to 20,970. The Nasdaq composite increased 22 points, or 0.4 percent, to 6,144.

Small-company stocks rose more than the rest of the market. The Russell 2000 index jumped 14 points, or 1.1 percent, to 1,397.

Bond prices fell. The yield on the 10-year Treasury note rose to 2.34 percent.