A federal judge here has dismissed an armed robbery case against a defendant solely because he was transferred back from the District to Prince George's County to continue serving a prison term there while his trial was pending here.

U.S. District Court Judge Charles R. Richey said the dismissal was required by a federal statute prohibiting such transfers, even though the defendant was the one who requested the transfer in the first place. Both his attorney and the prosecutor handling the case of acquiesced in the transfer.

The seldom invoked statute, which the defendant's attorney said he discovered after the transfer had already been made, states flatly that "if trial is not had on any indictment . . . Prior to the prisoner's being returned to the original place of imprisonment . . . the court shall enter an order" dismissing the pending case.

The government had argued that the defendant, Eric J. Randall, 20, of 5906 Southern Ave. SE, had waiyed any rights he had under the Interstate Agreement on Detainers Act (IAD) when he requested the transfer, and the case should not be dismissed.

Judge Richey found, as have judges in similar cases in other jurisdictions, that Randall's rights had been violated because the act had never been discussed with him and that he "never even knew, and had no reason to know, of the existence of his rights under the IAD."

Therefore, Richey said, the defendant did not "intentionally relinquish his right" and the case must be dismissed.

Randall was arrested last Dec. 21 and charged with the robbery of two men the previous night at 13th and Corcoran Streets NW.

He was arrested in a car that contained a pistol and a sawed-off shotgun and was subsequently identified by the victims, according to court papers.

After being freed on bond, he pleaded guilty to an unrelated charge in Prince George's County concerning a fight during a crap game the court record said.

He was sentenced to two years for assault and battery, and began serving the term in the Prince George's County jail on Jan. 17. On Jan. 18, he was indicted in the District for the December armed robbery.

When he was brought before Judge Richey for arraignment on Jan. 27, his attorney, Louis Fireison, transmitted Randall's request that he be returned to Prince George's to continue serving that term pending trial in D.C. "due to the correctional facilities in the District of Columbia."

Richey granted the request when the government failed to object. Fireison later raised the question of the legality of the transfer in a written motion, saying that the transfer request he made was done "in good faith" and was not an attempt to circumvent prosecution here.