By the Court,
Sanderson, C. J.This is an application for a mandamus to the Judge of the Twelfth Judicial District, commanding him to enter a judghnent of dismissal in an action pending in his Court wherein the relator and another-are plaintiffs and James P. Treadwell and others are defendants.
It appears that the plaintiffs.in that action, upon notice, moved the Court to enter a judgment dismissing it at their costs, as provided in the first subdivision of section one hundred and forty-eight of the Civil Practice Act. This motion was contested by defendant Treadwell, upon the ground that he had made a counter claim ; and .hence the plaintiffs could not dismiss against his consent; and in support of his opposition to the motion Treadwell relied upon the pleadings, proceedings and a stipulation made in the action between the parties thereto and an affidavit made by himself. After hearing the *169argument of counsel the Court denied the motion, thereby sustaining the grounds of the objection to the motion interposed by the defendant.
We do not think a mandamus will lie in this case. The real and substantial question presented for the decision of the Court by the motion to dismiss was whether the defendant had set up a counter claim against the plaintiffs upon which he was seeking affirmative relief. If he had not, the plaintiffs were undoubtedly entitled to the judgment which they asked, otherwise not. The solution of that question depended upon the judicial reading and construction of the defendant’s answer and the stipulation between the parties, and the effect of the latter upon the former. It was claimed on the part of the plaintiffs, first, that the counter claim made in the answer could not be legally made in the action ; and, second, that the counter claim had been withdrawn by the force and effect of the stipulation. Both of these propositions were denied by the defendant, and in deciding them the Judge acted judicially, not ministerially; and, having decided them according to the best of his ability, a mandamus does not lie to compel him to reverse his decision and render a different one. (Chase v. Blackstone Canal Company, 10 Pick. 244; The People ex rel. Doughty v. The Judges of Dutchess County, 20 Wend. 658.) This writ lies to compel a subordinate judicial tribunal to proceed and exercise its functions when it has neglected or refused to do so ; but when the act to be done is j udicial or discretionary the writ cannot direct what decision or judgment shall be rendered, nor can it be granted, after the inferior tribunal has acted, for the purpose of reviewing its decision. (The People v. Sexton, 24 Cal. 79.) If the Court has committed an error in denying the plaintiffs’ motion the same can be reviewed on appeal, which is a speedy and adequate remedy in the ordinary course of law within the meaning of the four hundred and sixty-eighth section of the Practice Act. To review errors is not the office of the writ of mandamus.
The case of The People ex rel. Smith v. The Judge of the Twelfth District, 17 Cal. 548, was a much stronger case for the *170relator than this. There the Legislature by a special Act had directed the Court to make an order changing the venue in a certain action then pending before it. The language of the Act was clear, explicit and mandatory, leaving nothing to the discretion of the Court. The Court nevertheless refused to make the order, and it was held that a mandamus would not ■lie.
Mandamus denied.
Mr. Justice Shafter, being disqualified, did not participate in the decision of this case.