St. Paul-based Ecolab Inc. met Wall Street expectations, even though its second quarter earnings and revenue were down over the same period a year ago.

The company had gains in its industrial, institutional and other segments, which offset sluggish performance from its energy sector to report net income of $302 million, or $1 per share, down from $311.4 million, or $1.02 per share. After adjustments for one-time occurrences, net income for the second quarter was $323.7 million, or $1.08 a share.

Total revenue for the quarter was $3.4 billion, down 5 percent from the second quarter last year. On a fixed currency basis and adjusting for acquisitions, sales for the quarter rose 2 percent for the provider of water, hygiene and energy technologies and services.

On a fixed currency basis, Ecolab's Global Institutional segment fared best with sales that rose 6 percent to $1.1 ­billion; sales in the Global Industrial segment rose 4 percent to $1.2 billion. The Global Energy segment sales, on a fixed currency basis, dropped 5 percent to $965 million.

"We delivered a solid second quarter as our focus on innovative products and effective on-site service drove ­better results and improved value for customers," Doug Baker, Ecolab's chairman and CEO, said in the earnings release.

Looking forward to the second half of the year, Ecolab continues to forecast adjusted earnings per share to increase 6 to 10 percent over the previous year.

The company expects foreign currency to continue to have a unfavorable effect on the company's overall sales and earnings for the year with a 6 percentage point drag on sales and a negative 7 percentage point effect on earnings per share growth.

"While the balance of 2015 presents us with continued challenging global economic conditions, and currency and energy markets remain dynamic, our full-year adjusted earnings per share forecast remains centered in the $4.45 to $4.60 range," Baker said. "We remain committed to driving attractive sales and adjusted earnings per share growth through the remainder of 2015."

Ecolab stock was up $5.38, or 5 percent, to close Tuesday at $113.77.

Patrick Kennedy • 612-673-7926