By Rogerio Jelmayer

SAO PAULO--Companhia Brasileira de Distribuicao, Brazil's largest retailer by revenue, posted a net loss in the second quarter, as the country's poor economic conditions hurt sales in some of its units and inflation increased the company's expenses.

The company, which is controlled by French retail group Casino Guichard-Perrachon SA, late Tuesday said it posted a net loss of 30 million Brazilian reais ($8.9 million) in the period, reversing a net profit of BRL358 million in the year ago period.

The company's revenue increased 6% in the period to BRL16.1 billion, thanks to its expansion in food sales. However, sales in nonfood division Via Varejo dropped 21.7% in the period.

After expanding just 0.1% last year, Brazil's economy is expected to contract around 1.7% this year. Despite poor economic conditions, Brazil's inflation remains at worrisome levels, currently at 9.25% per year, forcing the central bank to implement an aggressive Selic base rate hike. Currently, the Selic rate is at 13.75%.

Operational expenses were up 11.9% to BRL3.2 billion in the second quarter versus the year ago period.

CBD said earnings before interest, taxes, depreciation and amortization fell to BRL665 million from BRL1.09 billion a year earlier.

Write to Rogerio Jelmayer at rogerio.jelmayer@wsj.com

Subscribe to WSJ: http://online.wsj.com?mod=djnwires