Appeal by the defendant from a judgment of the County Court, Nassau County (O’Shaughnessy, J.), rendered October 10, 1986, convicting him of attempted sodomy in the first degree and sexual abuse in the first degree, upon a jury verdict, and imposing sentence. The appeal brings up for review the denial, after a hearing, of that branch of the defendant’s omnibus motion which was to suppress identification testimony.
Ordered that the judgment is reversed, as a matter of discretion in the interest of justice, and a new trial is ordered.
The hearing court properly denied the defendant’s motion to suppress evidence of the complainant’s identification of him two hours after the crime and her in-court identification testimony. The complainant’s identification of the defendant at the crime scene was not unduly suggestive. The purpose of the complainant’s observation of the defendant at that time was to confirm that the right person had been arrested (see, People v McCrimmon, 131 AD2d 598). Furthermore, the record indicates that the complainant’s observations of the defendant during the commission of the crime provided an independent source for her in-court identification (see, People v Brnja, 50 NY2d 366).
However, the trial court’s Sandoval ruling (see, People v Sandoval, 34 NY2d 371) was an improvident exercise of discretion requiring a new trial. The court improperly ruled that the prosecution would be allowed to cross-examine the defendant about a sexually deviant practice, not rising to the level of a crime, which had no logical bearing on the question of credibility. Since the prior "bad act” and the crime of attempted sodomy for which the defendant was on trial both involved deviant sexual conduct, the potential prejudice to the defendant was apparent and enormous. Moreover, in making this ruling, the court merely commented that the prior "bad act” was distinguishable from the acts underlying the indictment. It thus appears that the trial court failed to exercise its *395discretion in that there was no balancing of the probative value of the evidence against its prejudicial impact (see, People v Williams, 56 NY2d 236, 239-240).
Similarly, under these facts, it was an improvident exercise of discretion for the court to rule that the prosecutor would be allowed to question the defendant concerning the highly inflammatory and prejudicial underlying facts of his manslaughter conviction in which he beat his mother to death. Furthermore, harmless error analysis is inapplicable where, as here, the court’s errors had the effect of causing the defendant to refrain from taking the stand in his own behalf, and he was the only source of his defense (see, People v Brown, 84 AD2d 819, 820). In this regard, we note that the record reveals that the defendant’s trial counsel sought reconsideration of the Sandoval ruling on the basis that it was "crucial” that the defendant testify because he was the only possible witness who could controvert the testimony of the victim.
We decline to adopt the holding of the United States Supreme Court in Luce v United States (469 US 38), which, applying Federal Rules of Evidence, rule 609 (a), held that a defendant must testify in order to preserve for appellate review a claim of improper impeachment with a prior conviction. This is not the law in New York. The rule enunciated in People v Sandoval (supra) "does not impose any obligation upon a defendant to take the stand as a condition to its applicability” (People v Contreras, 108 AD2d 627, 628). In any event, we are reversing the defendant’s conviction in the exercise of our interest of justice jurisdiction.
In view of our determination directing a new trial, we do not reach the defendant’s remaining contention. Thompson, J. P., Bracken, Rubin and Spatt, JJ., concur.