TEL AVIV (MarketWatch) — Israeli stocks moved within a hairbreadth of a closing record set three months ago, finishing a holiday-shortened Wednesday higher on the back of strength in Israel Chemicals Ltd., Bank Hapoalim Ltd. and the energy stocks.

The Tel Aviv Stock Exchange’s benchmark TA-25 Index finished up 0.4% at 1,339.18, while the TA-100 Index (TA100) added 0.5% to stand at 1,216.65.

The TA 25’s closing record is 1,340.31, set Jan. 19.

The BlueTech 50 Index of technology and biomedical stocks added 0.4%, to 287.82.

Teva Pharmaceutical Industries Ltd. TEVA, +1.80% ranked as the TASE issue traded most actively, off 1.9%. Shares of fellow drugmaker Perrigo Co. PRGO, +0.52% gave up 0.7%.

Fertilizer producer Israel Chemicals ISCHF advanced 3.8%, while shares of agrichemicals specialist Makhteshim-Agan Industries Ltd. MAIXY ended little changed.

The banks were broadly mixed, with Hapoalim BKHPF, -3.89% up 0.8% but with Mizrahi Tefahot Bank Ltd. UMZRF off 1.3% and Israel Discount Bank Ltd. down 1%. Bank Leumi le’Israel BM was little changed, while First International Bank of Israel Ltd. moved 0.3% higher and Union Bank of Israel Ltd. ticked up 0.2%.

On Monday, the second day of a two-day closing on the TASE for a holiday, Moody’s Investors Service downgraded five Israeli banks, each by one notch. Hapoalim, Leumi and Mizrahi all went to A2 from A1, while First International and Discount were revised to A3 from A2 previously.

The outlooks on Leumi, Hapoalim and First International were upgraded by Moody’s to stable from negative, while Mizrahi and Discount are under review for possible downgrade.

The ratings moves reflect “expectations that the banks’ underlying profitability will remain weak due to their rigid cost bases. Their modest earnings-generating capacity prevents significant capital buildup,” which hinders their ability to absorb losses, the credit-rating company said in a report.

The Israeli banks’ similarly rated global peers “display a stronger mix of earnings and capital cushions,” Moody’s said.

Also Wednesday, the TA Oil and Gas Index moved up 2.5% to 1,307.41. Active and higher were Modi’in Energy LP, up 5.7%, as well as Ratio Oil Exploration LP, up 5.1%, and Avner Oil Exploration LP, up 2.5%.