Once upon a time, supermarkets were considered "defensive" investments. You could count on them to insulate your portfolio against losses in recessionary periods because people need to shop for food, no matter what.

Supermarkets supposedly had staying power. Recent troubles at Dutch grocer Royal Ahold (NYSE:AHO), owner of Giant stores, ripped the last shred of that illusion away from the sector.

The three biggest grocery chains in the country -- Kroger (NYSE:KR), Albertson's (NYSE:ABS), and Safeway (NYSE:SWY) -- haven't helped in recent years, either. A chart of the three pitted against one another (and the S&P 500) reveals that each is well off its five-year high and performing pretty consistently below the S&P. Another chart of a well-known company pummeling the S&P over the last five years gives us a clue as to why....

If you thought of Wal-Mart (NYSE:WMT) without even peeking at my chart, you're right. The Arkansas-based discounter has slowly dismantled how grocery retailing's done. And it shows no signs of stopping. It's now the No. 1 grocery retailer in the nation.

Given this roughshod reality, investing in supermarkets -- even at discounted prices -- is hardly compelling. Wal-Mart's not letting up anytime soon, and will continue to change the industry to the detriment of traditional supermarkets.

A deadly combination of low cost and increased convenience is at play here. With annual sales of $244.5 billion, Wal-Mart has the muscle to squeeze the absolute lowest costs from its suppliers. The company's renowned for not paying a cent more than it wants to, possessing unprecedented pricing power. Suppliers have to concede to Wal-Mart's wishes, as huge chunks of their revenues are increasingly tied to the retailer. Procter & Gamble (NYSE:PG), for instance, gets 17% of its sales from Wal-Mart. Gillette (NYSE:G) can thank the giant for 12% of revenues.

Wal-Mart brings a "low cost for us, low cost for the consumer" attitude to the grocery business, which saw slightly increased margins in a consolidating environment. These fattening margins, in part, likely enticed Wal-Mart into the sector.

Supermarkets are now struggling to keep up with the low-price game, and without Wal-Mart's clout and nationwide information and distribution networks, it's been a challenge. A UBS Warburg study found that Wal-Mart drives down grocery prices an average 13% in the markets it enters. That's one big "ouch" for supermarkets.

The other key here is convenience. Who wants to drive around, park, go in, and stand in lines at multiple stores? Most consumers want one-stop shopping.

Wal-Mart answers through its vast network of Supercenters, selling everything from tires to weed killer to Granny Smith apples under one huge roof. The average Supercenter is 190,000 square feet -- twice as big as a standard Wal-Mart and three times larger than the average supermarket.

The size of these sprawling stores inspired a recent Saturday Night Live skit featuring two Wal-Mart greeters marveling about the various climates and indigenous languages inside the store. They offered huge maps and rain ponchos to confused customers. It may be funny to us, but the competition's not laughing.

A recent AC Nielsen study found that since 1999, yearly customers' Supercenter visits are up 40%, while their supermarket trips are down 12%. Consider this, too, in light of the fact that Supercenters are found in only 63% of the U.S., while supermarkets are everywhere. These statistics will become even more pronounced as Wal-Mart builds more Supercenters. It's adding another 200 this year alone.

One truly must experience a Supercenter firsthand to understand the draw. When I lived in Memphis, Tenn., a few years ago, I did every bit of my grocery shopping across the Mississippi River. The Wal-Mart Supercenter in West Memphis, Ark., was my home away from home. The convenience of buying absolutely anything I wanted, cheaply and in one store, more than made up for the few extra minutes of driving. Plus, is any place so filled with Southern Gothic eccentricities as a 24-hour Wal-Mart Supercenter in West Memphis, Ark.? Sigh. I loved shopping there, and miss it still. But I digress....

Wal-Mart is targeting supermarkets with more than its gigantic Supercenters. It's also opening smaller grocery stores, called Neighborhood Markets, in urban areas where a 190,000-square-foot store just isn't possible. Supermarkets simply can't escape Wal-Mart.

Love it or hate it, the trend's the trend. An analyst with William Blair & Co. projects that supermarkets' share of the grocery market could decline from its current 53% to just 34% by 2011. And Moody's (NYSE:MCO), the revered credit agency, recently said that "non-traditional" food retailers are the main reason behind supermarkets' disappointing results over the last year.

Wal-Mart's not working alone. Warehouse clubs like Costco (NASDAQ:COST) are helping, much like fellow discounter Target (NYSE:TGT). Wal-Mart's definitely leading the charge, though, and posing the biggest threat.

Do you really want to bet against that monster with your investing dollars? You don't have to face this Goliath. Put your money elsewhere. There are many other investment opportunities outside Wal-Mart's scope and desire. I'm not suggesting that all supermarkets will disappear tomorrow. That'd be silly. However, rough conditions are only going to get rougher from here on out.

Kroger, for instance, has been cutting costs over the past year to be more price competitive. It'll have to keep it up, slicing already razor-thin margins even further. Albertson's recently reported a 29% plunge in profits. Safeway posted a whopping $1 billion Q4 loss last month because of its ill-fated acquisitions. Of the three, only Kroger looks, at best, sort of prepared to deal with Wal-Mart. It may be too little too late, however, with Wal-Mart charging ahead.

I'm not anti-supermarket. I shop at my local Harris Teeter (owned by Ruddick (NYSE:RDK)), and while I'd spend money at a Wal-Mart Supercenter in a heartbeat if there were one nearby, I don't like the thought of putting others out of business.

I am a realist, though, and given that Wal-Mart has set its sights on supermarkets, investing in them now seems akin to foolishly leaving money lying out, ripe for the taking.

LouAnn Lofton doesn't own shares in any of the companies mentioned, as evidenced by her profile. The Motley Fool is investors writing for investors.