When it comes to investing our money, history and memory do not often serve us well. So as the price of gold breaks records (see "Randgold CEO: Gold to Top $1,200 in 2008" on TheStreet.com TV), here are five investing lessons from the famous California "gold rush" of 1848, applied to today's hot commodities markets.

1. When many rush to find 'gold,' a few make a lot of money but most lose. This is the basic rule of bubbles. During California's gold rush, most gold diggers joined late in the game. The majority ended up wasting lots of resources and money, but not finding much gold.

Similarly, most who invest in a hot commodity (such as gold) do so just before it cools off, and therefore lose money. The relatively few who do make money are the ones who have the prescience to invest before the hot trend is evident in "the numbers" (see " Want to Invest in Commodities? Be a Proactive Economist").

It is not just psychology at play here, but a basic economic rule: for prices to go up, demand has to be higher than supply. Without that, a commodity wouldn't be considered "hot."

Therefore, one of the basic rules of investing applies: buy a commodity when few want to buy it, and sell when many want to buy it.

The exception to this rule is discussed in Want to Invest in Commodities? Be a Proactive Economist. It explains that the underlying economics of the increasing demand of commodities -- due to global population growth and alternative commodity uses (like ethanol from corn) -- and supply that cannot keep up, are driving prices upward (as with wheat, soy and corn). This supply-demand relationship should continue to rise for several years.

However, the demand for gold can be seen as artificial, because it is based on a belief in rising prices due to "other peoples' beliefs in rising prices," or otherwise known as speculation.

There is no real increase in the demand for gold and the supply is not really disappearing. Therefore, while in the short run gold might increase in price, over a longer run, it should go back down, as speculators start to take their profits and confidence in the economy increases.

2. The one who controls the land makes the money, not the one who finds gold. During the gold rush, those who controlled the land on which gold was found made the real money, not the gold diggers. Land owners, who controlled access to the limited resource, extracted significant profits in the form of leasing fees. Think of the average gold digger of the mid-1800s as a precursor to today's typical gambler in Las Vegas. Both mostly lose money by betting on the hope of striking it rich - fast.

So when investing in commodities, you want to examine who controls the access to a specific commodity -- the "land," if you will. Take oil, for example. Companies such as Exxon Mobile ( XOM), BP ( BP), Chevron ( CVX), Royal Dutch Shell ( RDS.A), ConocoPhillips ( COP) and Total ( TOT), practically control most of the world's access to oil. Therefore, these companies will continue to make money.

In the case of corn, seed companies like Monsanto ( MON) control access to the commodity. By controlling seeds of popular varieties, these companies can charge growers lucrative "access fees."

3. If you use gold and its cost goes up, you don't make money if you cannot increase your price. When a commodity's price go up, those who use the commodity as a component or ingredient in their product but cannot raise their prices at the same level, end up losing out. This is why gas stations close despite increasing oil prices. They cannot increase their prices as much at the same rate as the big oil companies increase the prices to them. The reasons: competition between gas stations creates price pressure downwards and consumers are somewhat price-sensitive -- even to gas, which doesn't have a mainstream alternative.

This is why Whole Foods ( WFMI) is in a tough place right now. Not only is the economy slowing down, but the company is facing more competition in its niche. Again, the costs of a company's "ingredients" are going up and it cannot transfer the full price increase to its customers, (because at some point, even Whole Foods' affluent customers become price-sensitive).

4. Enjoy the boomtown and escape the ghost town. To support the increased activity surrounding a commodity or industry, whole "ecosystems" are created. When the boom goes bust, those ecosystems are left to crumble.

During California's gold rush, whole towns were erected around "rich in gold" areas. These "boomtowns" were known for their striving businesses and overall activity. When the gold rush was over, those towns had no real viability and became "ghost towns."

As an investor, what you want to do is identify a "rush" or bubble and find companies that are building their business around it. A striking example of this (which ignores the previous gold rush lessons) is the range of new start-ups rushing to into gold exploration, driven by the record high prices of gold.

Dia Bras Exploration (ticker symbol: DIB, Toronto Stock Exchange) is an example of a short-lived company that does not have institutional memory of price decreases. It is worthwhile to watch it, and see whether they significantly increase their allocated resources for gold exploration. If they do, be ready to short them when you believe gold prices are going to fall, because they are likely to be stuck like the home builders in the U.S., with excess capacity that had cost too much to build.

5. The reliable money is in picks and shovels. During the gold rush, providing picks and shovels to dig the gold with, was more lucrative than the actual gold-digging. In agriculture, those are the equipment manufacturers (like Caterpillar ( CAT) and Deere ( DE)) and the chemical manufacturers (like Monsanto, Potash ( POT), DuPont ( DD)) who will make a lot of money selling more and better (higher priced) equipment to farmers flush with money.

Of course, the trick is to pick the likely winner within each category. To do so, you want to see which company is best positioned to capitalize on the growth in the space because it has the most upside potential in terms of products, global reach and cash to acquire other companies. However, instead of betting on one company -- which can provide higher returns, but more risk -- you can bet on the sector and "index it" (see index fund).

The ultimate lesson from the gold rush is that because the "picks and shovels" manufacturers make money regardless of the short-term movement of commodity prices, there is much less risk in investing in them instead of the commodity itself.

All of these lessons apply only if you invest with a bit longer-term (several years) time horizon. In the short-term, randomness, and temporary fluctuations might have stronger effects than fundamental economics. I believe in investing according to fundamental principles, not beliefs in next day's values, or how the "die" may roll. Rolling dice is much more fun to do in a Las Vegas casino, where nearby, the huge falls in real estate prices attest to the folly of crowds and speculators.

Moti Levi is the CEO and President of Life Group LLC, a Philadelphia-based wealth management firm. Levi holds a Ph.D. from The Wharton School of the University of Pennsylvania. Under no circumstances does the information in this column represent a recommendation to buy or sell stocks.

More from Investing

When Is It 'Worth It' to Work With a Financial Advisor?

When Is It 'Worth It' to Work With a Financial Advisor?

Amazon, Microsoft and Google Face Backlash over ICE, Military Deals

Amazon, Microsoft and Google Face Backlash over ICE, Military Deals

3 Great Stock Market Sectors Millennials Should Invest In

3 Great Stock Market Sectors Millennials Should Invest In

Why Millennials Are Ditching Stocks for ETFs

Why Millennials Are Ditching Stocks for ETFs

Trump's 'Space Force' Could Launch a $1 Trillion Industry, Morgan Stanley Says

Trump's 'Space Force' Could Launch a $1 Trillion Industry, Morgan Stanley Says