The residential property market in Queens is finally getting back in gear. In the second quarter, the median sales price rose 3.8%, to $355,000, from the same time last year, according to a quarterly report released Thursday morning. That marked the biggest year-over-year increase in six years, according to the Prudential Douglas Elliman and Miller Samuel Inc. report. The increase came after years of median prices in the borough either coasting or dropping, said Jonathan Miller, CEO of Miller Samuel. He attributed the uptick largely to a decline in inventory. During the second quarter, the number of listings dropped by a third, to 8,754, from the same period last year. Those who own their homes don’t have enough equity to trade up for their next purchase, Mr. Miller said, adding that tight lending conditions are also a factor.

“That is keeping the volume of new property entering the market low,” he said.

Consistent with that picture, the number of sales in the borough slipped 2.3% in the quarter from the same time last year, to 2,306. Every property type—including apartments and one-, two- and three-family homes, as well as nearly all regions of Queens—saw increases in median prices. The sole exception was central Queens, which harbors the neighborhoods of Floral Park and Jamaica Estates. Their prices were off by 2.5%.

Down in Brooklyn, the picture was more muted. There, the median sale price merely held steady, slipping 0.6% from the same period last year, to $477,108, according to the Elliman/Miller report. A separate report by The Corcoran Group was more bullish on Brooklyn, however. It reported a 4% rise in median prices to $497,000 in the second quarter, largely driven by a big spike in prices for new developments in the borough. New development prices rose 14% to $618,000, according to Corcoran.

“This spring has brought about amazing confidence in Brooklyn,” said Frank Percesepe, Corcoran’s Brooklyn regional senior vice president. “It has a lot to do with the fact that more and more top restaurants are coming to Brooklyn, and additional services are opening up in the entire borough.”

There were 1,988 sales in Brooklyn during the second quarter, up 2.4% from the same time last year, according to the Elliman/Miller report. Inventory also fell in Brooklyn, dropping 17.6%, to 5,772, in the quarter.

In areas like once-hard-hit Williamsburg, Brooklyn, the dark days of the recession are in the distant past. “Everyone has seen the resurgence of Williamsburg over the last three quarters,” Mr. Miller said.

Prices in Williamsburg and Greenpoint, Brooklyn, continued to rise in the second quarter, while limited inventory in those neighborhoods depressed sales volumes. The number of sales fell 29.6% in that area, Mr. Miller said.

“Williamsburg has a serious inventory problem; prices have gone up dramatically there,” Mr. Percesepe said. “We could sell so many more apartments if we had them.”