Opinion
February 21, 1986
Appeal from the Supreme Court, Cayuga County, Contiguglia, J.
Present — Denman, J.P., Boomer, Green, O'Donnell and Schnepp, JJ.
Judgment unanimously reversed, on the law, and petition reinstated. Memorandum: An appeal from a preanswer dismissal of a CPLR article 78 petition brought on by order to show cause is not an appeal from an ex parte order; therefore, the appeal is taken as of right.
The court erred in dismissing the petition sua sponte prior to service of a responsive pleading. Failure to exhaust administrative remedies is not an element of an article 78 claim for relief, but an affirmative defense which must be raised by respondent either in an answer or by preanswer motion or else be deemed waived (Matter of Consolidated Edison Co. v. Public Serv. Commn., 98 A.D.2d 377, 381, mod 63 N.Y.2d 424; Matter of Mallard v. Dalsheim, 97 A.D.2d 545, 546-547). The judgment dismissing the petition should be reversed, the petition reinstated and respondent directed to move or answer.