More than 30 D.C. police officers swarmed into the 7th and T streets NW neighborhood yesterday, shutting down at least temporarily one of the city's most notorious open markets for heroin and sending hundreds of people scattering to nearby alleys, streets and buildings.

Police on scooters and in squad cars and vans spread out over a four-block area with uniformed officers stationed on every corner and along the block while plainclothes narcotics officers mingled with the few people still left on the street. Five persons had been arrested by late last night.

The officers were greeted with shouts of praise from some residents who were able to walk along 7th Street sidewalks for the first time in months without having to push through thick crowds of drug sellers and buyers.

Police Capt. Michael L. Canfield, who supervised the operation, said the infusion of officers was a new tactic in police efforts to break up the open-air markets for heroin and other drugs.

Residents and businesses in the Shaw section of the city have been struggling for months to reclaim their neighborhood from junkies and drug dealers, who stash heroin under cars, in crannies of buildings and amid trash on the sidewalks.

Canfield said yesterday's action, which began about 4:30 p.m., was designed to confuse the drug crowd and disperse it, rather than to make arrests. He said the extra officers probably would be kept there for about a week, and would pursue any new crowds of people trying to sell drugs.

"We're trying to bring a little more uncertainty" to the drug traffic, Lt. Walter Albright said. "We're trying to clean up the narcotics problem."

Yesterday, just as officers had moved into the 7th and T street area, other officers were called to break up a new group of dealers gathering at 9th and U streets, a few blocks away.

"It's like a bubble," one officer said, "you squeeze it one place and it pops out in another."

D.C. Police Chief Maurice T. Turner said recently that heroin use in the city "is epidemic" and is causing the crime rate to soar. He said yesterday that the new tactic was not part of his previously announced "war on heroin," but promised that the main attack will come soon. He declined to provide details to avoid tipping off drug dealers.

Yesterday's police action, he said, "was to move people. I'm going to lock them up."

The area around 7th and T became a major center of illegal drug sales during the past year after dealers and junkies were largely scared away from 14th and U streets, a longtime hub of narcotics trafficking, by a similar heavy influx of police.

Narcotics officers said the drug crowd, which can number more than 300 people, typically spends most of the day in the area of 7th and T and then migrates back to 14th and U late at night.

Meanwhile, Turner said, the police department has begun transferring 40 uniform division officers to the narcotics branch. This will bring the number in that unit to 150 -- the highest in the department's history.

So far this year, 74 persons have died of drug overdoses in the city, a record high. The most recent overdose death was that of a D.C. postal employe whose body was found yesterday.

Turner also said there have been 3,421 armed robberies in the District this year, 985 more than at this date last year. He attributed the increase, in part, to drug addicts who commit crimes to earn money for narcotics.