A man who was shot by an intruder in a Prince George's apartment complex won $90,000 from his former landlords yesterday after he sued them, alleging failure to maintain proper security in the building.

The settlement, which was approved by Circuit Court Judge Jacob S. Levin, came on the eve of a scheduled trial on the suit. The case is one of the first of its kind in the county.

The suit was brought by Mardy Errera, 54, who was shot in the abdomen in August 1979 in the hallway of his apartment complex at 5804 Annapolis Rd., Bladensburg. Errera was walking toward his apartment door when the shooting occurred. His apartment was then robbed by the assailant.

Errera charged that the shooting and robbery occurred because the apartment managing company, G.H.H. Associates Inc., did not maintain the locks on the front and rear doors of the apartment building. The suit charged the company with reckless conduct.

On the night of the shooting, Errera entered his apartment building without using a key to the front door, he testified in a deposition.

As a result of the shooting, Errera spent several weeks in the hospital and was forced to sell his restaurant, Jimmy's Crab House, because of poor health, according to Errera's lawyer, Joseph DePaul. Errera has since moved from the apartment complex to a house in Lanham.

The assailant was never caught, DePaul said.