Sales at the nation's retailers were flat in July for the second month in a row as consumers, worried about their jobs, shopped selectively.

The Commerce Department's report Tuesday showed that much of the lackluster performance came from a record drop in sales at gasoline stations, reflecting lower prices at the pump. Sales at automobile dealerships also fell. 

But that masked strength elsewhere, including sales of sporting goods, health and personal care products, and clothes, which all posted healthy gains. Consumers also ate out more last month. 

Tuesday's report was a bit better than many analysts were predicting. They had forecast that total retail sales would drop by 0.2 percent in July. 

Economists say that layoffs, eroding consumer confidence and stock market volatility contributed to shoppers being more choosy. 

The flat reading on retail sales last month came as merchants heavily discounted items to lure shoppers and as the first wave of nearly $40 billion in tax-rebate checks began arriving in mailboxes. 

Consumer spending, which accounts for two-thirds of all economic activity, has been a main force keeping the struggling economy afloat. Some economists worry that consumers might curtail their spending, should the labor market seriously worsen, and throw the economy into recession. 

Trying to avert a recession, the Federal Reserve has slashed interest rates six times this year, totaling 2.75 percentage points. Many economists predict another rate cut when the Fed meets next on Aug. 21. 

In July, car sales fell by 0.5 percent, erasing the 0.5 percent increase the month before. 

Overall retail sales excluding automobile sales rose by 0.2 percent in July, slightly better than the 0.1 percent gain many analysts were predicting. In June, retail sales, excluding autos, fell by 0.2 percent. 

Sales at gasoline stations declined by a record 4.2 percent in July, after a 3.6 percent drop as prices at the pump retreated after peaking in May. 

However, sales for a category that includes sporting goods, hobby shops and music stores rose by 1.2 percent last month, after a 0.7 percent increase. Sales at clothing stores rose 0.9 percent, following a 0.5 percent decline. 

At health and personal care stores, sales rose 1.7 percent, following a 0.4 percent increase. Sales of electronics and appliances grew by 0.7 percent, down from a 1.8 percent rise. 

For bars and restaurants, sales rose 1 percent, on top of a 0.7 percent increase. 

Last week, reports from major retailers showed that consumers flocked to discounters but stayed away from department stores, such as Saks, and apparel chains, including Gap and The Limited.