
    (February 23, 1911.)
    S. C. FROST et al., Respondents, v. IDAHO IRRIGATION COMPANY, LIMITED, et al., Appellants.
    [114 Pac. 38.]
    Order Bringing in New Defendants — Power of Court to Set Aside — Parties—Necessary—Indispensable.
    (Syllabus by tbe court.)
    1. Under tbe provisions of Rev. Codes, sec. 4354, tbe trial court bas no power or right to dismiss an action over the objection of a defendant, who bas filed an answer and cross-complaint seeking affirmative relief, but is required to enter judgment upon tbe merits of tbe issue presented by tbe cross-complaint.
    2. Tbe district court has power and jurisdiction to set aside and vacate an order inadvertently made, bringing in new parties as defendants, and to strike from tbe files the answer and cross-complaint of such defendant, where no right has been acquired by such defendant except the right to file such answer.
    3. In an aetion to adjudicate the priorities of appropriation of the waters of a stream, where there are a large number of plaintiffs and defendants, and much time has been consumed and large expense incurred in taking the testimony in said cause, and, after the close of such evidence and the decree is in preparation, the court makes an order requiring new parties to be brought in as defendants, and such defendants appear and file an answer and cross-complaint, and motion is made by other defendants to set aside and vacate the order of the court making such new defendant a party, and the court is of the opinion that the bringing in of such party would require a retrial of said cause, and put the plaintiffs and defendants to the expense of going over the ground which had already been gone over in the evidence, and that said order had been made inadvertently, it is not error to sustain the motion to set aside and vaeate the same, and to strike the answer and cross-complaint of said defendant from the files.
    
      4. In an action to determine the priority of rights of appropriation from a stream of water, all parties claiming right of appropriation should be made either parties plaintiff or defendant, but the failure to make all such parties who claim a right of appropriation parties to said suit will not affect the rights and interests as adjudicated between the parties to such action and determined by the court.
    5. An appropriator of water from a stream is a proper party to> a suit affecting the right of appropriation of the waters of such stream, but such person is not an indispensable party, and a judgment rendered in said cause would be just as effective as to the rights and interest of all those who were parties to said aetion, as between themselves, and whose rights have been adjudicated,, as. though such other person had also been made a party.
    APPEAL from the District Court of the Fourth Judicial District, for Lincoln County. Hon. Alfred Budge, Judge.
    An aetion to adjudicate the priorities of the waters of Big-Wood river. From an order vacating an order to make additional defendants the said defendants appealed.
    
      Affirmed.
    
    N. M. Ruick and Waldemar Yan Cott, for Appellant Idaho. Irr. Co.
    “Plaintiff in an action will be precluded from dismissing-his action on his own motion where an answer has been filed. showing defendant to be entitled to and praying for affirmative relief. The consent of the adverse party is necessary in such case.” {Hypotheek Bank v. Bauch, 5 Ida. 752, 51 Pac. 764; 14 Cyc. 407.)
    Under a statute of California identical with our own in all respects under consideration here (Cal. Code Civ. Proc., sec. 581), the supreme court of that state has uniformly held that the court has no authority to dismiss an action over the objection of a defendant who has filed an answer or cross-complaint seeking affirmative relief. {Rodgers v. Parker, 136 Cal. 315, 68 Pac. 975; Mott v. Mott, 82 Cal. 413, 22 Pac. 1140, 1142; Water Go. v. Allen, 132 Cal. 432, 64 Pac. 713.)
    If the Idaho Irrigation Co. did not claim any rights in this case and was not a necessary party, then there might be a reason to dismiss the ease; but when it comes in and makes a claim to the subject matter, then the court, of its own motion, must retain such party in the case, in order to adjudicate its rights, and so as finally to put an end to the litigation. {Bank of Hailey v. Bews, 3 Ida. 486, 31 Pac. 816.)
    In the above fiase, this court considered the identical sec. 4113, and held that all persons must be made parties to the suit when that is necessary to make a complete determination of a controversy. (See, also, Frost v. Alturas Water Go., 11 Ida. 294, 81 Pac. 996.)
    The purpose of the court is not only to simplify proceedings but to avoid, as far as may be, a multiplicity of suits. {Willman v. Friedman, 4 Ida: 209-213, 95 Am. St. 59, 38 Pae. 937; 15 Cyc. PI. & Pr. 58iU588; U. S. v. N. P. B. Co., 134 Fed. 715, 67 C. C. A. 269; Sherman v. Parish, 53 N. Y. 483, 490.)
    Sullivan & Sullivan, Hawley, Puckett & Hawley and Paul S. Haddock, for Respondents.
    If the Idaho Irrigation Co., Ltd., was claiming any of the identical water rights for the particular tracts of the plaintiffs or defendants, then it might be a necessary party, but they are simply claiming a separate and distinct water right of their own from a different date. True, it is from the same stream, but it is not necessary to determine its priority in order to have a complete determination between the parties to this action as to their water rights as between themselves. If this be true, then the appellant, although a proper party-defendant, cannot demand recognition as an indispensable party. (15 Am. & Eng. Eney. P. & P. 610.)
    When a contest can be settled without affecting rights of others, there is no ground or reason for bringing in any other parties. Nor is such procedure required by sec. 389, Cal. C. C. P. (same as our sec. 4113). {Lytle Greek Water Go. v. Perdew, 65 Cal. 455, 4 Pac. 426.)
    The power of the court to set aside an order which has been made through inadverteuce or mistake is too well established to 'require argument. {Hall v. Polack, 42 Cal. 218; Ex parte Hartman, 44 Cal. 32; Wig gin v. Superior Court, 68 Cal. 398, 9 Pac. 646; Baker v. Fireman’s etc. Go., 73 Cal. 182, 14 Pae. 686; Wunderlin v. Gadogan, 75 Cal. 617, 17 Pac. 713; Kaufman v. Shain, 111 Gal. 16, 52 Am. St. 139, 43 Pae. 393; People v. Curtis, 113 Cal. 68, 45 Pae. 180; Servatius v. Pickel, 30 Wis. 507; State v. Bragg, 63 Mo. App. 22; Mudge v. Hull, 56 Kan. 314, 43 Pae. 242; Am. Hosiery Co. v. Riley, 12 Abb. N. C. (N. Y.) 329.)
    Every court of superior jurisdiction has power to control its own orders and to direct where and under what conditions they shall be operative. (15 Eney. P. & P. 349; 29 Cyc. 1518.)
    Orders are not regarded as res adjudicata with the same strictness as judgments. Accordingly, every order made in the progress of a cause may be rescinded or modified upon a proper ease for such relief being made out. (15 Eney. P. & P. 350, 354.)
    It is well settled that whatever can be done upon motion to the court may, by the court, upon further motion, bo altered, modified or wholly undone. {Belmont v. Erie R. Co., 52 Barb. (N. Y.) 637; Fanning v. Dunham, 4 Johns. Ch. (N. Y.) 35.)
    The court had jurisdiction to set aside an order made inadvertently and ex parte. {Wiggin v. Superior Ct., supra; Sherburne v. Strawn, 52 Kan. 39, 34 Pac. 405.)
    
      An action may be dismissed notwithstanding the filing of a cross-complaint, where at the time of the dismissal the cross-complaint has been stricken from the files by the court acting within its authority. (Alpers v. Bliss, 145 Cal. 565, 79 Pac. 171.)
   STEWART, C. J.

This is an action to adjudicate the rights of a large number of alleged appropriators of water from Big Wood river, a stream flowing through Blaine and Lincoln counties, this state. There are some twenty or more plaintiffs, and several hundred defendants. A referee was appointed by the court and the evidence taken, and after the close of the evidence the plaintiffs, by their attorneys, made an application to the court to make the Idaho Irrigation Company, Ltd., and J. G. White & Co. parties to the action. This application was based upon the affidavit of J. H. Hawley, one of counsel for the plaintiffs.

This affidavit, among other things, recites that the evidence in said eause has been taken by the referee, and that the taking of such evidence has not yet been completed, but that said cause is still open for the admission of other and further evidence; that the Idaho Irrigation Company, Ltd., is a corporation organized under the laws of the state of Idaho, and that the articles of incorporation of said company were filed in the office of the secretary of state on or about the 22d day of December, 1905, and that said corporation was not in existence at the time of the commencement of the action; that on information and belief the Idaho Irrigation Company, Ltd., claims some right to the water and use of the water involved in this controversy, the extent and amount of said rights being to affiant unknown; but all of the rights of said corporation are inferior in right to that of each of the parties or the answering defendants herein; that J. G. White & Co. is a corporation, organized and existing under the laws of the state of Connecticut, and doing business in Lincoln and Blaine counties, in this state, and is engaged in the construction of dams, impounding the waters of said Big Wood river, and is acting in conjunction with the Idaho Irrigation Company in the construction of said dams and impounding said waters, and in the construction of works for the purpose of storing and diverting the waters of said stream sought to be litigated in this action; that said defendants have not been made parties to said suit, and are not only claiming the use and the right to the use of the waters herein being litigated, but are also impounding the waters of said Big Wood river, and diverting the waters of said stream so impounded, and thereby obstructing the flow of the waters of said stream to the injury of the plaintiffs and defendants; that affiant is of the opinion and judgment, as an attorney of this court, that the complete determination of the controversy herein, and of the rights of the respective parties to the flow of the stream herein being litigated, cannot be had without the presence of the said Idaho Irrigation Company, Ltd., and said J. G. White & Co. as parties to the action, and makes this affidavit for the purpose of securing an order of this court and of the judge thereof, directing that said parties, and each of them, may be brought into this suit as parties defendant thereto, and that each of them be served with a copy of the summons in this action and of the order referred to.

This motion was made ex parte and without notice to the defendants in said action, or to the Idaho Irrigation Company, Ltd., or J. G. White & Co. Upon the hearing the court made the following order: “It is, therefore, upon motion of Hawley, Puckett & Hawley and Paul Haddock, attorneys for the plaintiff, ordered and directed that such corporations and each and both of them be brought into this action as parties defendant therein, and that a copy of the summons herein and a copy of the complaint herein and of this order be served upon each of said parties in like manner as provided for the service of the summons. ’ ’

The Idaho Irrigation Company, Ltd., and J. G. White & Co. were served with summons and a eopy of the order, and appeared in said cause and filed demurrers, and afterward withdrew such demurrers and were permitted by the court to file answers and a cross-complaint. Thereafter counsel for defendants filed the following motion: “Comes now the undersigned, counsel in the above-entitled case, and in behalf of the respective clients move the court to vacate and set aside the order heretofore on the 6th day of August, 1909, made and entered herein, bringing in the Idaho Irrigation Company, Limited, and J. G. White & Company, a corporation, as parties defendant in this cause, and to strike from the files their answer and cross-complaint, upon the following grounds and for the following reasons, to wit:

“First, that said order was made ex parte and upon application of the plaintiffs, and without notice to us or to our clients.
“Second, for the reason that said order could not be properly or legally made by the court at said time, in that all of the evidence in the cause had been taken and the taking of the evidence closed, and the matter was then pending before the court for final judgment and decree.
‘ ‘ Third, it is contended and insisted by said parties defendant, that said order will necessitate the retaking of all the evidence heretofore taken in the cause as proper evidence therein, and would thus work a great hardship and entail large expense upon all the parties thereto.”

Counsel for the Idaho Irrigation Company, Ltd., objected to the court sustaining said motion upon the ground:

“(1) That it proposes to dismiss an action as to the defendant Idaho Irrigation Company, Limited, which defendant has on file in this court in said action a cross-complaint seeking affirmative relief against the plaintiffs and its several eodefendants.
“ (2) The defendant, the Idaho Irrigation Company, Limited, having been made a defendant in order to enable a complete determination of the controversy before the court to be had, to wit, the adjudication of the rights of the respective users of water of Big Wood river and its tributaries, there is no power in the court at this time to revoke such order. ’

The motions to strike and dismiss were heard upon the objections of the Idaho Irrigation Company, Ltd., and after hearing the court made the following order:

“. . . . after due consideration, hereby orders and directs that the answers and cross-complaints of the said Idaho Irriga-. tion Company and J. G. “White & Co., be, and the same are hereby stricken from the files, and the said parties are hereby dismissed from said action, for the reason that it appears to the court that the said above-named parties failed and refused to appear in said cause until after the time when the testimony in the above-entitled cause had been fully submitted to the referee, and the referee’s report had been made to the court, and'for the further reason that said order directing that the above-named parties be made parties defendant in said cause was inadvertently made at the date that the said order was entered, and was made only for the purpose of preventing the said parties above named from interfering with the waters of the Big “Wood river, under a temporary order based upon the report of the referee herein, and not for the purpose of making them parties defendant, or requiring them to appear by answer and cross-complaint, for the purpose of putting in any testimony with reference to any rights in- and to the waters of said Big “Wood river or its tributaries, and for the further reason that said order was made ex parte, and without notice to the attorneys for the defendants, and would require the retaking of all the testimony heretofore taken, which would entail enormous and in the opinion of the court unnecessary and unwarranted expense.”

From this latter order and judgment the Idaho Irrigation Company, Ltd., appeals to this court.

It is argued on behalf of appellant that after the court granted the motion of the plaintiffs to make the Idaho Irrigation Company, Ltd., a defendant, and summons was issued and served upon such defendant, and such defendant appeared and filed an answer and cross-complaint seeking affirmative relief, the court had no power or jurisdiction to dismiss the action as to such defendant, but was required under the provisions of sec. 4354 to render judgment on the merits; while on the part of counsel for respondents it is argued that it is not a question of dismissing the action, but rather did the court err in vacating and setting aside an interlocutory order made inadvertently and without notice. It must be conceded that the court had no power or right to dismiss an action over the objection of the defendant who has filed an answer or cross-complaint seeking affirmative relief, but is required to-enter judgment on the merits of the issue presented by the cross-complaint. (Rev. Codes, sec. 4354; Mott v. Mott, 82 Cal. 413, 22 Pac. 1140, 1142; Water Company v. Allen, 132 Cal. 432, 64 Pac. 713; Rodgers v. Parker, 136 Cal. 315, 68 Pac. 975; 14 Cyc. 407.)

Does this rule of law, however, apply to the facts of this case? The Idaho Irrigation Company, Ltd., was not made-an original defendant; it was not in existence at the time the-action was commenced. Application was made 'by the plaintiffs to bring in such defendant after months had been consumed in taking the evidence, and after the evidence had been concluded and the decree was in preparation. "When the court’s attention was called to the order by objections made by counsel for defendants, and upon further consideration, the court set aside the order making the Idaho Irrigation Company a defendant, and dismissed its cross-complaint upon the ground: “. . . . that it appears to the court that the said above-named parties failed and refused to appear in said cause until after the time when the testimony in the above-entitled cause had been fully submitted to the referee, and the referee’s report had been made to the court, and for the further - reason that said order directing that the above-named parties be made parties defendant in said cause was inadvertently made at the date that the said order was entered, and was. made only for the purpose of preventing the said parties above named from interfering with the waters of the Big Wood river, under a temporary order based upon the report of the referee herein, and not for the purpose of making them parties defendant, or requiring them to appear by answer and cross-complaint, for the purpose of putting in any testimony ■ with reference to any rights in and to the waters of said Big - Wood river or its tributaries, and for the further reason that said order was made ex pa/rte, and without notice to the attorneys for the defendants, and would require the retaking of " all the testimony heretofore taken, which would entail enor- - mous, and, in the opinion of the court, unnecessary and unwarranted, expense.”

There can be no doubt but that the court, at the time this latter order was made, was fully convinced that the order making the irrigation company a defendant was inadvertently made, and inadvertently made for the reasons given in the •order. If the order making the irrigation company defendant was inadvertently made by the trial court, there can be no question but that the trial court had power to set such order aside. No right had as yet been acquired by the Idaho Irrigation Company by reason of the court’s order making it a defendant, except the right to appear and file an answer. The court, no doubt, was of the opinion that by permitting the order to stand allowing the irrigation company to be made a defendant, it would require a retrial of said cause, and put the plaintiffs and defendants to the expense of going over the identical ground which had already been gone over, and that in its judgment it would be better that the order be set aside and the irrigation company relegated to its right to commence a new action, in case it desired to litigate its right to the waters of said stream.

The general rule as to the power of the court to control and direct its orders is stated in 15 Eney. Pl. & Pr., p. 349, as follows: “Every court of superior jurisdiction has, in the absence of statutory limitations, power to control its own orders, and to direct when and under what conditions they shall be operative. Orders are not regarded as res ad judicata with the same strictness as in the case of judgments; accordingly every order made in the progress of a cause may be rescinded or modified upon a proper case for such relief being made out.”

Discussing this matter the supreme court of California, in the case of People v. Curtis, 113 Cal. 68, 45 Pac. 180, says: “The power of the court to cause its records to correctly set forth the orders which it has actually made, as well as to set aside an order which it has made through inadvertence or mistake, is too well established to require argument (Hall v. Polack, 42 Cal. 218; Wiggin v. Superior Court, 68 Cal. 398, 9 Pac. 646; Crim v. Kessing, 89 Cal. 478, 23 Am. St. 491, 26 Pac. 1074; Kaufman v. Shain, 111 Cal. 16, 52 Am. St. 139, 43 Pac. 242); and if the question of mistake or inadvertence is disputed, the decision of the judge upon any controverted fact is not open to review. ' In the present case, the statement in the bill of exceptions that the motion to dismiss was based upon the ground that the other cases involved only the same question as those presented in the ease just tried, is not controverted, and it follows, not only that the statement of the court that it did not intend to dismiss any other cases must be accepted as conclusive, but also that the entry by. the clerk dismissing any other eases was made under a mistake on his part in failing to comprehend the scope of the order. "When these facts were brought to the notice of the. court, it became its duty, either' at the instance of the district attorney or upon its own motion without any suggestion from either party, to vacate and set aside the entry that had been made by the clerk.”

In the case of Wiggin v. Supreme Court, 68 Cal. 398, the court quotes with approval the case of Hall v. Polack, 42 Cal. 218, and says: “Where the judgment of a court has been deliberately exercised in a cause, and a final result reached as a conclusion thereof, there are good reasons why it should not be disturbed except by the formal methods prescribed by statute, but rulings, orders, and even judgments inadvertently made are not the result of judgment, but of oversight, neglect, or accident, and are subject to correction by the judge or court making them. ’ ’

Counsel for appellant contends, however, that it was the duty of the court, under the provisions of Rev. Codes, sec. 4113, to make the Idaho Irrigation Company a party defendant, when it appeared that the presence of said company was necessary to a complete determination of the controversy, and that having made said irrigation company'a party defendant, the court should have permitted said defendant to remain in the ease as a party defendant. It is true that in an action to determine the priority of rights of appropriation all parties claiming a right of appropriation should be made either parties plaintiff or defendant to the action; but it does not follow that a failure to make all persons parties who claim the right of appropriation affects the validity of a judgment rendered determining the rights of such parties as have been made parties to the suit. An appropriator of water from a stream is a proper party to a suit affecting the right of appropriation to the waters of such stream, but such person is not an indispensable party, and a judgment rendered in said cause will be just as effective as to the rights and interests of all those who were parties to said action and whose rights have been adjudicated, as though other persons had also been made parties, and in this case the decree rendered by the trial court will be effective and binding upon all parties to the suit, and an adjudication of their respective rights as between such parties, even though the Idaho Irrigation Company was not made a party to said action; and the rights and interests of the Idaho Irrigation Company can in no way be affected, and such judgment would in no way determine the rights of said company, or have any force or effect against such company. (Farmers’ etc. Ditch Co. v. Riverside Irr. Dist., 14 Ida. 450, 94 Pac. 761.)

The trial court no doubt took the view that as the Idaho Irrigation Company was not an indispensable party, it would be in the interests of economy and justice not to permit the order making it a defendant to stand. It may be possible that the irrigation company, after such decree is entered, may not desire to contest the rights fixed by such decree, and if it should, an independent action may be commenced for that purpose, and in that action it may contest the rights of any of the parties fixed by said decree, while others it may admit and make no contest against, and by this method of procedure great expense may be saved by the parties, rather than to permit the order to stand making such defendant a party, and thus place the record in such condition that a retrial would have been necessary; and because of such facts the trial court concluded that the order making said defendant a party was inadvertently made, and therefore set aside said order and struck the answer and cross-complaint of the Idaho Irrigation Company. In this the court committed no error. Judgment is affirmed. Costs awarded to respondents.

Ailshie, J., concurs.

Sullivan, J., sat at the hearing, but did not participate in the opinion.  