A jump in auto and gasoline sales salvaged an otherwise lackluster June for U.S. retailers, while an inflation gauge jumped by twice as much as expected, suggesting a long-awaited economic recovery will be sluggish.

Commerce Department data on Tuesday showed sales at U.S. retailers rose 0.6 percent from a month earlier, ahead of economists' expectations for a 0.4 percent advance.

However, outside of autos and gas stations the sales results were disappointingly weak, indicating consumers remained wary of stepping up discretionary spending despite signs the recession may be drawing to a close.

We fell off a cliff at the end of last year and we're at a relatively flat point right now, Rebecca Blank, undersecretary for economic affairs at the Commerce Department, told Reuters in an interview. The movement is in the right direction but it's not strong enough yet to call this clear signs of the recovery.

A separate report from the Labor Department showed producer prices jumped 1.8 percent last month, far outstripping forecasts for a 0.9 percent gain.

Another set of data showed business inventories fell for a ninth consecutive month, pressured by a steep drop in stocks of motor vehicles and parts.

U.S. stock indexes were little changed near midday, while U.S. government debt prices fell. The dollar was down slightly against a basket of currencies.

Investor attention was focused on quarterly earnings from investment bank Goldman Sachs Group Inc , which were much stronger than expected.

Other quarterly results in a busy week for corporate earnings reports pointed to an economy that was bottoming but struggling to pick up much momentum.

Pharmaceutical and consumer products maker Johnson & Johnson posted lower earnings, but the results still beat analysts' expectations. The chief executive of railroad CSX Corp said the worst of the declines appeared to be over, but it was unclear how long it would take to recover.

With unemployment at a 26-year high and likely to keep climbing, consumers have been reluctant to splurge, and that has left businesses feeling conservative about hiring and investment. President Barack Obama said he expected unemployment to keep ticking up in the coming months.

Still, U.S. Treasury Secretary Timothy Geithner struck a somewhat more upbeat note, saying he saw signs of confidence returning to the U.S. financial sector.

JUST THE BASICS

Excluding autos and parts, which recorded a 2.3 percent gain, retail sales were up a modest 0.3 percent, short of analysts' expectations for a 0.5 percent advance.

Gasoline stations showed strong gains, helped by rising prices. The average price per gallon of gas rose to $2.68 in June from $2.32 in May, according to government data.

Excluding both autos and gasoline, retail sales were down 0.2 percent, the fourth consecutive monthly decline. Department stores and restaurants were among the laggards.

The comforting glow from the strong January-February retail figures is starting to fade as poor consumer numbers continue to pile up, said Michael Feroli, an economist at JPMorgan in New York.

The Producer Price Index, which measures prices received by farms, factories and refineries, recorded its steepest gain since November 2007, the Labor Department said.

Core prices, which strip out volatile food and energy costs, rose a much greater-than-expected 0.5 percent, boosted by cars and trucks. Analysts polled by Reuters were looking for a 0.1 percent increase in the core PPI.

A sluggish economy plus inflationary pressure would normally be considered a dangerous stagflationary mix, but economists see little reason to fret over price pressures when there is so much slack in the economy.

High unemployment keeps wages in check. Energy prices, the primary cause of last month's rise in inflation, have come down in the past two weeks, which should help cool prices.

U.S. business inventories fell 1 percent in May, according to Commerce Department data. That was steeper than the 0.8 percent decline that economists had predicted. The inventory of motor vehicles and parts dropped 4.2 percent in May, the biggest decrease since a 5.4 percent drop in July 2005.

Companies have been purging inventory as the weakening economy crushed demand, and that contributed to the deepening of the recession in late 2008 and early 2009. Many economists expect that pattern to reverse soon, which should help lift economic growth in the second half of the year.

(Additional reporting by Mark Felsenthal in Washington and Ryan Vlastelica in New York; Editing by Neil Stempleman)