Judgment unanimously affirmed, without costs, and judgment declared in favor of defendants. Memorandum: Defendant Sheriff appointed plaintiff a Deputy Sheriff of Monroe County April 1, 1967. He was assigned to the road patrol and performed, in addition to other duties, all the duties of a police officer. At the time of his appointment plaintiff was a resident of Monroe County, but on March 24, 1975 he moved his residence to Marvin Hill Road, Springwater, New York which is located in contiguous Livingston County. On June 3, 1976 defendant informed plaintiff that unless he moved back to Monroe County he would be subject to discipline or discharge for violation of departmental rules requiring that he be a bona fide resident of Monroe County. Plaintiff instituted this declaratory judgment action asking that defendant be permanently enjoined from disciplining or discharging him. He contends that he is exempt from residence requirements under applicable provisions of the Public Officers Law and that the enforcement of such residence requirements denies him equal protection of the law. The trial court dismissed his complaint. Since plaintiff sought a declaratory judgment, the complaint should not have been dismissed without declaring the rights of the parties (Lanza v Wagner, 11 NY2d 317, 334). Deputy Sheriffs are local officers within the purview of the Public Officers Law (Matter of Winkler v Sheriff of Queens County, 256 App Div 770; see, also, Public Officers Law, § 2.) One of the statutory qualifications for holding local office is that the officer be a resident of the political subdivision or municipal corporation of the state within which his official functions are required to be exercised (Public Officers Law, § 3, subd 1). Members of the "police force of any political subdivision or municipal corporation” are exempt from this requirement if they live in a county within the state which is "contiguous” to the political subdivision or municipal corporation by which they are employed (Public Officers Law, § 3 subd 2). Similar to the requirements of these sections are the provisions of section 30 (subd 1, par d; subd 4) of the Public Officers Law which state that a local public office becomes vacant when a qualified incumbent ceases to be a resident and is not exempt from the residence requirements of the statute. The dispositive issue on this appeal is whether the Sheriff’s department is a police force of the county and whether a Deputy Sheriff, as a member of the Sheriff’s department, is therefore exempt from the residence requirements of the statute. In an effort to resolve the issue, both parties cite various statutes and rulings either identifying Sheriff’s deputies with local police officers or distinguish*1018ing them from local police officers. A Sheriff's department does exercise police functions, but it is more than a police department and the Sheriff and his deputies have traditionally been distinguished from other police forces. The Sheriff is a constitutional officer (NY Const, art XIII, § 13) acting both as an officer of the court and a conservator of the peace (County Law, § 650). The deputies act in the service of the public or the municipality in the performance of criminal duties, but they act as the personal agent of the Sheriff in the performance of various civil duties (Matter of Flaherty v Millikin, 193 NY 564; Isereau v Stone, 3 AD2d 243). Because of this identity between the Sheriff and his deputies, the Sheriff has broad discretion in appointing his deputies and removing them which differs from employment rights governing members of a police force (see Matter of Sirles v Cordary, 49 AD2d 330, affd 40 NY2d 950; Amico v Erie County Legislature, 36 AD2d 415, affd 30 NY2d 729). These broader duties of the deputies and broader responsibility óf the Sheriff for their acts have traditionally resulted in distinguishing them from other police officers. Indeed, in enacting the exemptions found in section 3 of the Public Officers Law, the Legislature had no difficulty in specifying that special Deputy Sheriffs were exempt from the residency requirements of the statute (§ 3, subd 2-b), thereby indicating that it considered a specific exemption for that class of Deputy Sheriffs necessary and that they were not otherwise exempt by the provisions of subdivision 2 of section 3 as members of a police force. We think the language of the exemption is not broad enough to include Deputy Sheriffs and that the Sheriff may lawfully discipline or remove a deputy who violates a departmental ruling requiring that deputies be residents of the county. Such residence requirements do not violate the equal protection clause of the Fourteenth Amendment to the United States Constitution (see Detroit Police Officers Assn, v City of Detroit, 385 Mich 519, cert den 405 US 950; and see, also, McCarthy v Philadelphia Civ. Serv. Comm., 424 US 645). (Appeal from judgment of Monroe Supreme Court—declaratory judgment.) Present—Cardamone, J. P., Simons, Hancock, Denman and Witmer, JJ.