
    HARDEN, Appellant, v. WARE, Respondent.
    No. 6486;
    April 7, 1880.
    Mortgage.—There can be but One Action for the Recovery of any debt secured by mortgage.
    Mortgage—Foreclosure Ordered Though not Asked in Complaint. Whenever it appears by the pleadings or proof in a case that the plaintiff is entitled to recover judgment upon a debt secured by mortgage, the court may by its judgment direct the sale of the mortgaged property, even though such relief has not been specifically demanded in the complaint.
    
    Actions.—The Old Distinction Between Legal and Equitable Remedies will not prevent a California court, in a simple action to recover on a promissory note, from directing by its judgment a sale of property upon which it has been made to appear that such note was expressly secured.
    Action—Mistake of Remedy.—A Suit Does not Fail because of the plaintiff's’ happening to mistake the form of his remedy.
    Bills and Notes.—In a Simple Action to Enforce Payment of a promissory note, allegations in the answer to the effect that the note was secured by mortgage does not constitute a good plea in either bar or abatement.
    APPEAL from Fourth Judicial District, San Francisco County.
    J. C. Bates for appellant; Chas. H. Phelps for respondent.
    
      
       Cited and approved in Johnson v. Polhemus, 99 Cal. 246', 33 Pac. 908, where the court intimated that if the scope of the ease made by the plaintiff involved a foreclosure of the mortgage, the technical manner of bringing the matter into court was a minor consideration.
      Cited in Hansen v. Wagner, 133 Cal. 71, 65 Pac. 143, to the proposition that if the answer was defective in not repeating the allegations of the complaint as to the execution of the mortgage, etc., it wa& aided and the defect cured by the allegations of the complaint.
    
   SHARPSTEIN, J.

The defendant in his answer does not deny any of the allegations of the complaint, which is in the ordinary form of one upon a promissory note. But it is alleged in the answer that the note sued upon is secured by a mortgage bearing even date therewith, executed by the defendant to the plaintiff upon, real estate, which is particularly described in the answer. A copy of the mortgage is annexed to the answer and made a part thereof. It was recorded on the day of its execution; and the defendant alleges that it has never been foreclosed, released, transferred or abandoned. The court found that the defendant made and delivered the note as alleged in the complaint; that the plaintiff was the lawful owner and holder thereof; that no part of the principal or interest had been paid; and that at the date of said findings there was due to the plaintiff on it the sum of three thousand and fourteen dollars. And the court found that all the allegations of -the answer in respect of the execution of a mortgage as security for the payment of said note were true. As a conclusion of law, the court found that the plaintiff held a mortgage upon real estate to secure the payment of the note, which is a “debt” within the meaning of section 726 of the Code of Civil Procedure, and as such must be recovered in an action of foreclosure; and ordered judgment to be entered for the defendant.

If the defendant had not set up the mortgage in his answer, the plaintiff would have been entitled, upon the findings of the court upon the other facts, to a judgment for the amount-which he claimed in his complaint. And before the enactment of section 723, Code of Civil Procedure, or any statute embodying a similar provision, the existence of the mortgage would not have affected his right to recover upon the note in an action at law. The section of the code above referred to provides that “there can be but one action for the recovery of any debt .... secured by mortgage upon real estate, .... which action must be in accordance with this chapter”: Chap. 1, title 10. “In such action the court may by its judgment direct a sale of the encumbered property (or so much thereof as may be necessary), and the application of the proceedings of the sale to the payment” of costs, expenses, “and the amount due to the plaintiff.” The judgment in such a case must be the ordinary one of foreclosure.

The exact meaning of the section is not quite clear to our comprehension. For instance, when it says that the “action must be in accordance with the provisions of this chapter,” and' then omits to state anything in regard to the form of the action or the proceeding in it until the stage is reached where it becomes necessary to render a judgment, the intention of the legislature is not plainly apparent. In the case before us, “but one action” has been brought for the recovery of debt. To that extent, at least, the case is within the provision of the code above cited. Now, if in this action a judgment can be rendered upon the allegations of the parties which will be in strict accordance with that provision of the code, we know of no valid reason why it should not be done. There is no controversy as to the right of the plaintiff to recover, in some form of action, the sum for which he demands judgment. Conceding, then, that the only judgment to which he is entitled upon the allegations contained in the answer is one in conformity with the provisions of the code bearing upon this question, why is he not entitled to a judgment in that form? It is true that neither party demands such a judgment. But in any case in which an answer is filed, the court may grant to a plaintiff “any relief consistent with the case made by the complaint and embraced within the issue”: Code Civ. Proe., sec. 580.. If there be no answer, the relief granted to the plaintiff “cannot exceed that which he shall have demanded in his complaint”: Id. This clearly implies that whenever it is shown by an answer that the plaintiff is entitled to relief in excess of that which he demands in his complaint, if embraced within the issue, he shall have it. Now, the plaintiff in this case, as before stated, was entitled, upon his own allegations, to a judgment; and the answer simply shows that the judgment should differ only in form from that which is demanded in the complaint. In other words, the defendant should obtain all the relief to which his answer shows him entitled, under the law interpreted as he insists it should be, by having a judgment entered for the amount demanded by the plaintiff, containing a direction for the “sale of the encumbered property,” etc. We think that it would be doing no violence to the provision of section 726 of the code to construe it as if it read as follows: “There can be but one action for the recovery of any debt secured by mortgage; and whenever it appears by the pleadings or proofs in a case that the plaintiff is entitled to recover a judgment upon a debt so secured, the court may by its judgment direct the sale of the encumbered property,” etc. It seems to us that this would satisfy every requirement of that section. As Comstock, J., says, in Emery v. Pease, 20 N. Y. 64: “This is probably not the view in which the suit is brought, nor is it in accordance with the prayer of the complaint; but relief is to be given consistent with the facts stated, although it be not the relief specifically demanded: Code, see. 275. And in determining whether an action will lie, the courts are to have no regard to the old distinction between legal and equitable remedies. Those distinctions are expressly abolished: Code, see. 69. A suit does not, as formerly, fail because the plaintiff has made a mistake as to the form of the remedy.” It is unnecessary to state that our own code in this respect is substantially the same as that of New York. Of course we do not mean to be understood as holding that the plaintiff, upon the allegations of his complaint in the absence of those of the answer, would be entitled to a judgment of foreclosure. But what we do mean is, that the answer shows beyond any doubt that the plaintiff is entitled to such a judgment, and that such a judgment would not be inconsistent with the case made by the complaint, and that it is embraced within the issue. Whether the judgment be in the form demanded by the complaint or in the form which the answer requires that it should be, the plaintiff recovers upon, the note sued on; and the only difference is, that in the latter case the judgment directs that recourse shall first be had to the encumbered property for its satisfaction. Beyond that the two judgments would be essentially the same. Besides, we do not think that the allegations of the answer constitute either a good plea in bar or in abatement. We do think, however, that the defendant is entitled to have a judgment rendered in accordance with the case which he makes; and that is all that he can equitably claim. As the statute upon which he relies does not attempt to prescribe the form of action, but does prescribe, in clear and unambiguous language, the form of judgment in a case like that which his answer presents, and as that answer is found by the court to be true, it would seem to follow that the defendant is only entitled to the relief which his answer shows him entitled to. It must be borne in mind, however, that this conclusion is largely based upon the fact that, before the enactment of any statute upon this subject, the plaintiff would have been entitled to the judgment demanded in his complaint, and that the matters alleged in the answer of the defendant would have been wholly irrelevant; and we are not permitted to presume that by the enactment of that statute the legislature contemplated any greater change in the law as it before existed than is clearly expressed in the act by which the change is wrought. As before stated, the only change expressly made in the law applicable to this ease is as to the form of the judgment. In that respect the code relating to the subject must be complied with, and with that in view we make the following order:

Judgment reversed, and cause remanded to the superior court of the city and county of San Francisco, with directions to enter a judgment upon the findings in favor of the plaintiff for the amount therein found to be due him upon the note sued on, together with interest which has since accrued and costs; and that in all other respects said judgment be made to conform to the provisions of chapter 1, of title 10, of the Code of Civil Procedure..

We concur: Myrick, J.; Thornton, J.  