THE COURT.
After further consideration, we are satisfied that our former opinion, written by Mr. Justice Tyler, upon the question involved in this appeal makes a correct disposition of that question. We, therefore, adopt so much of said opinion as deals with and is decisive of said question. It is as follows:
"Mandamus to compel the dismissal of a cross-complaint.
"The record presents the following facts: Petitioner commenced an action in the Superior Court on January 21, 1927, against one Beck, defendant. An answer was filed March 3, 1927, and at the same time defendant filed a cross-complaint. On April 4, 1927, an answer to the cross-complaint was filed. The case was set for trial on March 31, *Page 181 1932, which was more than five years after issue was joined upon the original complaint, but less than five years after issue joined upon the cross-complaint. On the day set for the trial, upon motion regularly made, the original plaintiff, petitioner herein, moved the respondent court to dismiss `the action' under the provisions of section 583 of the Code of Civil Procedure. The court thereupon on its own motion dismissed the original complaint and answer which had not been brought to trial within five years, but it refused to dismiss the cross-complaint and answer upon which issue the five-year period had not yet run. The court thereupon proceeded to trial upon the cross-complaint, and petitioner then procured the alternative writ herein.
"It is conceded that no question as to the exercise of judicial discretion by respondent court is here involved. The motion to dismiss was addressed solely to the mandatory provisions of section 583 of the Code of Civil Procedure, which reads as follows: `Any action heretofore or hereafter commenced shall be dismissed by the court in which the same shall have been commenced or to which it may be transferred on motion of the defendant, after due notice to plaintiff or by the court on its own motion, unless such action is brought to trial within five years after the defendant has filed his answer, except where the parties have stipulated in writing that the time may be extended.' The controversy here presented relates to the proper interpretation to be placed on the word `action' as contained in the provision above quoted. Respondents, in support of the action of the trial court, contend that the issue joined upon a cross-complaint is a separate and distinct action from that joined on the complaint itself; that the two are severable, and the failure of the one has no effect upon the other. Petitioner argues that the word `action' means the entire proceeding or suit, and that when the parties have failed to bring `such action' to trial within five years, then the entire proceeding, cross-complaint and all, must be dismissed. We are of the opinion that petitioner's contention cannot be sustained. Preliminarily it may be stated that a diligent search of the authorities fails to reveal a single case where the precise situation was presented or passed upon by any court in the various jurisdictions. Authority on principle, however, is not wanting. *Page 182 [1] "One of the objects of the reformed or code procedure is to simplify the pleadings and conduct of actions, and to permit of the settlement of all matters of controversy between the parties in one action, so far as may be practicable. And to this end most of the codes have provided that the defendant, in an action may, by appropriate pleadings, set up various kinds of new matter, or cross-claims, which must otherwise have been tried in separate actions. Generally speaking, in most of the states this new matter is broad enough to embrace all controversies which upon previous statutes might have been the subject of setoff, and all claims which under the adjudication of courts might have been interposed as defenses by way of recoupment, and secures to a defendant all the relief which an action at law, or a bill in equity, or a cross-bill would have secured on the same state of facts prior to the adoption of the code. The object of these remedial statutes is to enable, as far as possible, the settlement of cross-claims between the same parties in the same action, so as to prevent a multiplicity of actions. These cross-actions, however, are still distinct and independent causes of action, so that when properly interposed and stated the defendant becomes in respect to the matters pleaded by him, an actor, and there are two simultaneous actions pending between the same parties wherein each is at the same time both a plaintiff and a defendant. (Francis Bro. v. Edwards, 77 N.C. 271;Davidson v. Remington, 12 How. Pr. (N.Y.) 310; Cragin v.Lovell, 88 N.Y. 258.) The same view has been taken by our appellate courts, for the cases recognize and establish the principle that the issues presented upon a cross-complaint and answer are entirely separate and distinct from the issues raised upon the original complaint and answer. In the case of Millar v. Millar, 51 Cal.App. 718 [197 P. 811], it is held that the purpose of allowing a cross-complaint is to avoid a multiplicity of suits and thereby save vexation and expense, and that such a situation involves merely a consolidation of two independent actions arising out of or related to the same transaction. See, also, Mott v. Mott, 82 Cal. 413 [22 P. 1140], and Warner v. Darrow, 91 Cal. 309 [27 P. 737]. The code provisions also recognize this distinction. Section 581 of the Code of Civil Procedure authorizing a dismissal of a suit by the plaintiff before trial provides that such dismissal *Page 183 may not be had where affirmative relief is sought by way of cross-complaint, and our courts in construing said section so hold. (Islais Salinas Water Co. v. Allen, 132 Cal. 432 [64 P. 713]; Clark v. Hundley, 65 Cal. 96 [3 P. 131];Robinson v. Placerville Sacramento Valley R. Co., 65 Cal. 263 [3 P. 878].) For like reasons a cross-complainant cannot dismiss his cross-complaint after the filing of an answer thereto, asking affirmative relief. (Rodgers v. Parker,136 Cal. 313 [68 P. 975].) [2] It therefore seems plain to us that the issues raised from the cross-complaint and answer are completely severable from the issues upon the original complaint and answer, and a plaintiff has no such control over a cross-complaint as would entitle him under the circumstances to ask for its dismissal under the code provision invoked."