NEW YORK, June 29 —The S&P 500 and the Nasdaq were flat in volatile trading today on worries over faster interest rate hikes even as recent data painted a dour picture for the economy, while a boost from Goldman Sachs shares kept the Dow afloat.

Investors fretted over the impact of hefty rate increases on the US economy, as data highlighted the contraction of the US economy in the first quarter amid a record trade deficit following a Tuesday report that showed US consumer confidence hit a 16-month low.

Markets were choppy in the first hour of trading, with investors pointing to quarter-end rebalancing of portfolios as also feeding into higher volatility.

"That (rebalancing of portfolios) was part of the reason why you got a little bit of a lift in the market over the past week, although it seems to be fading because the weakness that preceded the decline to the mid June lows brought equity allocations lower than their targets," said Liz Ann Sonders, chief investment strategist at Charles Schwab & Co.

Federal Reserve chair Jerome Powell said there was a risk that interest rate increases will slow the economy too much, but persistent inflation was the bigger worry.

Cleveland Federal Reserve Bank President Loretta Mester advocated for another 75 basis points (bps) interest rate hike in the US central bank's July meeting, if economic conditions remained the same.

San Francisco Fed President Mary Daly and New York Fed President John Williams also backed further rapid interest rate hikes on Tuesday and pushed back against fears that sharply higher borrowing costs will trigger a steep downturn.

Goldman Sachs Group Inc rose 1.3 per cent, boosting the blue-chip Dow Jones Industrial Average, after BofA Global Research upgraded the investment bank to "buy" from "neutral", saying it was well-positioned to outperform in a likely worsening economic environment.

The benchmark S&P 500 was on track for its biggest drop in the first half of a year since 1970, and along with the Dow and the Nasdaq was headed toward a second straight quarterly decline for the first time since 2015.

At 10:28 a.m. ET the Dow Jones Industrial Average was up 95.03 points, or 0.31 per cent, at 31,042.02, the S&P 500 was up 0.97 points, or 0.03 per cent, at 3,822.52 and the Nasdaq Composite was down 8.27 points, or 0.07 per cent, at 11,173.27.

General Mills Inc gained 5.6 per cent after the Cheerios maker's sales surpassed estimates despite higher prices.

Bed Bath & Beyond Inc plunged 21.8 per cent after the home goods retailer reported a drop in quarterly comparable sales and said its CEO, Mark Tritton, had stepped down.

Declining issues outnumbered advancers for a 2.26-to-1 ratio on the NYSE and for a 2.56-to-1 ratio on the Nasdaq.

The S&P index recorded one new 52-week high and 35 new lows, while the Nasdaq recorded eight new highs and 182 new lows.— Reuters