The U.S. economy expanded less than forecast in the second quarter after a weaker start to the year than previously estimated as companies slimmed down inventories and remained wary of investing amid shaky global demand.

Gross domestic product rose at a 1.2 percent annualized rate after a 0.8 percent advance the prior quarter, Commerce Department figures showed Friday in Washington. The median forecast of economists surveyed by Bloomberg called for a 2.5 percent second-quarter increase.

The report raises the risk to the outlook at a time Federal Reserve policy makers are looking for sustained improvement. While consumers were resilient last quarter, businesses were cautious — cutting back on investment and aggressively reducing stockpiles amid weak global markets, heightened uncertainty and the lingering drag from a stronger dollar.

“We’re just muddling through,” said Joseph LaVorgna, chief U.S. economist at Deutsche Bank Securities Inc. in New York, who had forecast a 1 percent gain in second-quarter GDP. “Consumer spending looks good, but the problem is that the rest of the economy is soft. The economy remains vulnerable to downside risks. The Fed is right to be cautious.”

Private fixed investment, which includes residential and business spending, dropped at a 3.2 percent pace in the second quarter, the most in seven years.

With Friday’s report, the Commerce Department also issued its annual revisions, updating the data back through 2013. The first-quarter’s reading was revised from a previously reported 1.1 percent gain.