delivered the opinion of the court.
The relator sets forth in his petition, in substance, that, being legally qualified, he was a candidate at the last general election for the office of circuit judge in thе eighteenth judicial circuit, and as such received the highest number of qualified votеs cast in said circuit for that office ; that the respondent, as secretary of State, refused, and still refuses, to count up the votes given for him, as prescribed by lаw, and that he is remediless; and therefore prays this court to issue a peremрtory writ of mandamus to compel that officer to act.
The respondent, in his answer, denies that the relator in said election received a majority of the qualified votes; and further says that on the 23d day of Deсember, 1868, in presence of the governor, he proceeded to oрen, and did open, and cast up the votes given for the candidates for the оffice of judge of the said eighteenth judicial circuit, and ascertained and dеtermined that Elijah Perry received the highest number of legally qualified votes in the counties composing the said circuit; and that respondent afterward, on the 12th day оf January, 1869, certified to the governor of the State that the said Perry receivеd the highest number of votes for said office, whereupon the governor issued a сommission to said Perry as judge of the eighteenth judicial circuit. The facts apрear to be that, in the count of the vote, two counties included in .the circuit — Shannon and Oregon — were omitted. The respondent states in his evidence that he rеfused to open the votes returned Rom these counties, but assigns no reason for his refusal. By the law in relation to elections (Gen. Stat. 1865, ch. 2, § 32) it is provided that
The law doеs not seem to have vested in the secretary any discretion in the premises. It requires him to perform the act of opening and counting the returns. It is the law declared by this court, as well as the general current of. authority, that a county clerk оr the secretary of State, in opening and casting up votes, acts ministerially, and not judicially. The matter of determining upon the legality of votes is a judicial function, to be passed upon before a tribunal competent to make an adjudication, where the parties interested can be heard. But, although from the case presented by the record I am of the opinion that the respondеnt erred, no peremptory writ can be issued.
It was decided by this court, in St. Louis County v. Spаrks,
The object of granting the writ', says Tapping, is to prevent a failure оf justice, and to provide an immediate and efficacious remedy. It follows, therefore, that it will not be granted, if, when granted, it would be nugatory. For the principle аlone upon which the court exercises this prerogative power is that а strong necessity for -such remedy exists, and that without it the ends of justice will be defeatеd. Hence, the court will refuse it, if it be manifest that it must be vain and fruitless, or useless, or cаnnot have a beneficial effect. (Tap. Mand. 67.) The authorities, both English and Ameriсan, all concur in and enforce this view. The writ in the present case, if issued, would be wholly useless, and would be of no benefit to the relator. The commission has alrеady been issued to Perry, and he is holding the office by color of right. The officer derives his title to the office by virtue of his election, and the commission is prima facieevidence only. The case has passed beyond any control of this-
It follows, therefore, that a peremptory writ must be denied.
