Stocks cut early gains on Tuesday, with the Dow and Nasdaq slipping into negative territory as Wal-Mart weighed.

Wal-Mart Stores Inc fell 4.2 percent to $59.85 after reporting results. It was the biggest decliner on the Dow.

The Dow Jones industrial average <.DJI> was up 0.80 points, or 0.01 percent, at 12,950.67. The Standard & Poor's 500 Index <.SPX> was up 1.03 points, or 0.08 percent, at 1,362.26. The Nasdaq Composite Index <.IXIC> was down 2.20 points, or 0.07 percent, at 2,949.58.

Stocks had opened higher after euro zone finance ministers secured a deal that will enable Greece to avoid a March default.

(Reporting By Ryan Vlastelica; editing by Jeffrey Benkoe)