Inflation is problematic for all businesses. They have to deal with rising costs, and they're not all able to pass rising prices along to customers without negatively affecting demand. For customers, it also leads to problems related to affordability -- and that may be contributing to a rise in theft, or "shrink," as the industry calls it.

One theme investors may have been noticing this past earnings season is that many retailers are complaining about a rise in shrink, and how that is hurting their businesses more so than in the past.

Dick's Sporting Goods blames shrink on worsening profits

On Aug. 22, Dick's Sporting Goods (DKS 1.43%) reported its second-quarter earnings numbers, for the period ending July 29. While the sporting goods retailer's revenue of $3.2 billion was relatively resilient and grew by nearly 4% year over year, the company's bottom line totaled $244 million and was down by a mammoth 23%. Its gross profit margin of 34% was down nearly two percentage points compared to a year ago.

The company also reduced its guidance for diluted earnings per share (EPS) for the year. It's now expecting between $11.33 to $12.13 per share, down from its previous forecast of $12.90 to $13.80 per share. CEO Lauren Hobart said that "our Q2 profitability was short of our expectations due in large part to the impact of elevated inventory shrink, an increasingly serious issue impacting many retailers."

Shares of Dick's Sporting Goods plunged after earnings as the outlook and underwhelming bottom line spooked investors. Rather than being up over 20% as it was when heading into earnings, shares of Dick's Sporting Goods are now down 3% year to date.

Dollar Tree may stop selling some items altogether

Even discount retailers aren't immune to these risks. Last month, Dollar Tree (DLTR 0.04%), a top dollar store chain in the U.S., reported similar issues: A worsening gross profit margin due to shrink. The company's top-line results were encouraging, as Dollar Tree's same-store sales growth was nearly 8%. But despite reporting $7.3 billion in net sales for the period ending July 29, which was $555 million more than what it reported in the prior-year period, its gross profit rose by barely $10 million. The company's gross profit margin of 29.2% was noticeably lower than the 31.4% it posted a year ago.

As with Dick's Sporting Goods, Dollar Tree says shrink is the big reason behind the company's worsening margins. Management is going to have stores lock up certain products, and in more extreme circumstances, it says it may simply discontinue certain items.

It's not the only retailer resorting to such measures, as home improvement retailer Home Depot says that it is locking up items as low-priced as $50. Home Depot has also been hiring more security guards to tackle its theft problems.

One retailer that beat expectations

Not all retailers are blaming poor results on shrink. One discount retailer, Big Lots (BIG), reported impressive results last week, as its loss was smaller than what Wall Street was projecting. Its adjusted loss per share of $3.24, also for the period ending July 29, beat expectations that called for a loss of $4.11.

The company even reported a slight increase in gross margin, from 32.6% a year ago to 33%. Net revenue of $1.1 billion was down 15%, however, as the company's top line wasn't all that strong. While Big Lots didn't blame its results on shrink, CEO Bruce Thorn did caution that it is still facing headwinds: "Our core lower-income customer remains under significant pressure and has limited capacity for higher-ticket discretionary purchases." And given the uncertainty ahead for the economy, the company didn't provide full-year guidance.

Is retail too risky a place to invest in right now?

Between inflation and shrink, it's becoming increasingly difficult to pick good retail stocks to invest in. Dollar stores are struggling, as are larger businesses. But the good news is that these aren't problems that should weigh down retail businesses for the long haul. Inflation is slowing down, and retailers will adapt and make changes to bring down their levels of shrink, even if that means not carrying some products.

For long-term investors, this is creating some buying opportunities. While some investors are dumping stocks due to these developments, that's putting those stocks at some more attractive valuations. Dollar Tree is trading at a 52-week low, and Dick's Sporting Goods isn't at its low, but it did drop 17% last month.

If you're willing to stick it out amid these challenging headwinds, in the long run, you could make a big profit by investing in top retailers that investors have recently become bearish on.