Walmart (WMT -1.75%) posted surprisingly strong second-quarter earnings last week that sparked a rally for its stock while also lifting the shares of many of its retailing peers. The company had plenty of good news for investors, including progress in its e-commerce growth initiatives. But the bigger news was a jump in customer traffic at its massive network of physical locations.

CEO Doug McMillon and his executive team held a conference call with analysts to put those encouraging trends in perspective. Below are a few highlights from that presentation.

One woman whispers into the ear of another. The latter woman is holding shopping bags.

Image source: Getty Images.

Firing on all cylinders

Customers tell us that they feel better about the current health of the U.S. economy as well as their personal finances. They're more confident about their employment opportunities. And, with warmer weather, sales of seasonal items like pools, air conditioners, swimwear, and gardening supplies really popped in May compared to April. No doubt we were aided by tailwinds during the second quarter.
-- McMillon

Several positive trends came together to power unusually strong growth for the retailing chain. Comparable-store sales gains jumped to 4.5% from 2% in the prior quarter, which marked Walmart's best result in over a decade. The Sam's Club division posted a six-year high, too.

Some of that growth had to do with seasonal weather factors that depressed sales slightly in the prior quarter. But Walmart's core business is also performing well, with its grocery segment putting up the best numbers in nine years. That suggests the sales rebound could persist.

E-commerce update

"Our omnichannel initiatives are contributing to comp sales growth and providing customers with new levels of shopping convenience," said McMillon.

Walmart executives refer to their collective e-commerce initiatives as a "digital transformation," and that term aptly describes its aggressive investments in this niche. The company passed 700 in-store automated pickup "towers" this quarter, extended its grocery pickup offering to 1,800 locations, and reached 1,100 new brands added to the website, year to date.

These programs helped digital sales growth tick back up to 40% from 33% last quarter, which kept the retailer on track for its 40% annual sales gain. Management did say that profitability still isn't where they want it to be in this channel, and that likely played a role in the retailer's overall 4% dip in operating income.

Looking ahead

We expect growth at Walmart U.S., excluding fuel, to be around 3% for the year and expect Sam's Club, excluding fuel, to be about 3%, which reflects a negative impact from reduced tobacco sales of about 200 basis points. The comparisons are a bit more challenging in the back half of the year and particularly in the third quarter due to the hurricanes last year, which drove higher-than-expected sales.
-- CFO Brett Biggs

The healthier customer traffic trends convinced management to lift their growth outlook in the core U.S. business to 3% from 2%. The Sam's Club segment got a big upgrade, too, and Walmart now sees that division growing by around 3% rather than staying flat in the fiscal year, which ends in late January.

The company still believes overall losses in the e-commerce segment will grow this year as compared to last year. However, management is encouraged by the fact that rising profits from the physical side of the business are supporting aggressive digital initiatives that, ideally, will pay off over time.

"The strength of our company," particularly in the U.S. stores, CFO Biggs told investors, "gives us the ability to invest in parts of our business as we deem necessary in the short term to ensure we win with the entire business long term."