This is an action to foreclose fifty bonds of a railway company, of the par value of one thousand dollars each, exclusive of coupons, and to have the proceeds, after judicial sale, applied to the payment of a certain promissory note made to plaintiff by Behrend Joost, the appealing defendant, for twenty-five thousand dollars. An agreement was made by defendant Joost that the bonds might be sold for payment of the note, and plaintiff’s right to a judicial foreclosure is not denied, but the right to a personal judgment against defendant for a deficiency, if any there be, is questioned.
Upon filing the answer, plaintiff moved for judgment on the pleadings on the ground that the answer denied none of the material allegations of the complaint. The court granted the motion, and ordered judgment in accordance with the prayer of the complaint, including a deficiency judgment, to which order defendant excepted, and this appeal is from the judgment against this defendant. The other defendants do not appeal. The pleadings are verified.
The answer did not deny the allegations of the complaint, which fully and clearly set forth a good cause of action on foreclosure, but the answer avers: “That *206prior to and at the time of the making and delivery by him, defendant, to plaintiff, of the promissory note and the instrument in writing mentioned, a copy of which is contained in said complaint, it was expressly agreed and understood by and between plaintiff and defendant that it, plaintiff, should and would rely upon and look to said fifty (50) first mortgage bonds of the San Francisco and San Mateo Railway Company, mentioned in said instrument in writing, exclusively for the payment of said note, .... and that no further or personal or general liability or application or judgment should he sought or obtained; .... that it was upon said terms and conditions, and not otherwise, that said note and written instrument were made and delivered to plaintiff.”
The written instrument referred to is the agreement by which the.bonds were placed as collateral security for the payment of the above note, and reads as follows:
“And as collateral security for the payment of the above note, and interest to grow due thereon, I have deposited with Bradford Investment Co. the following property, to wit, fifty first mortgage bonds of the San Francisco and San Mateo Railroad Company of the denomination of one thousand dollars each, numbers from 951 to 1,000, both numbers inclusive, aud should the said note, or any part thereof, or the interest to grow due thereon, remain due and unpaid after the same should have been paid according to the tenor of said note, I hereby irrevocably authorize and empower said Bradford Investment Company, or its assigns, to sell and dispose of the above-described property, or any part thereof, at public or private sale, with five days previous notice to me of such sale, and from the proceeds arising therefrom to pay the principal, interest, charges, and the costs of sale, and the balance, if any, to pay over to me or my representatives upon demand. In case of deterioration of any of the above securities, or fall in the market value of the same, I hereby promise and agree to reduce the amount of said note, or to increase the security in proportion to such deterioration or decrease *207of value, in default of which this note shall be considered due under the above stipulation. On the payment of above note, interest, and charges, according to the terms thereof, this agreement shall be void, and the above-described securities returned to me.
“Bbhrend Joost.”
Defendant’s brief was constructed upon the theory, apparently, that the learned judge who tried the case refused to consider the defense, because the answer did not aver that the agreement relied upon was in writing.
The first point made by defendant is, that it will be presumed that the agreement was in writing, if evidence thereof should be deemed to be necessary. (Citing Reagan v. Justice’s Court, 75 Cal. 255; Emerson v. Bergin, 76 Cal. 202; Broder v. Conklin, 77 Cal. 336; Barnard v. Lloyd, 85 Cal. 132.)
To this point, plaintiff replies that the cases cited are to the effect that, where the statute of frauds requires the agreement to be in writing, it will be presumed that it was so, in order to support the complaint; that at common law the rule applied to the declaration, and not to the plea; that the rule under the code system of pleading applies to the complaint, but not to the answer.
It would seem to me clear, and in every way consonant with reason that, if the rule is that where an agreement, to be valid, must be in writing, it may yet be pleaded without alleging it to be in writing, we certainly may plead a like agreement in defense without alleging whether it is in writing or not.
Both before and after the passage of the statute of frauds, the rule was the same at common law. ( Wakefield v. Greenhood, 29 Cal. 597; Vassault v. Edwards, 43 Cal. 458, and numerous cases since.) But plaintiff says this rule had application to the declaration, and not to the plea (citing 1 Chitty on Pleading, 304, 534; Stephens on Pleading, 331); and he further says it has been expressly so held under our code pleading as to the answer. (Citing Reinheimer v. Carter, 31 Ohio St. 586; Wakefield v. Greenhood, supra; Bliss on Code Pleading, sec. 354 a; *208Maxwell on Code Pleading-, 92; Case v. Barber, T. Raym. 450.) The case cited from 29 California, supra, did not involve this point; it related only to the sufficiency of the complaint, which was held good although it did not allege the agreement to have been in writing.
This court said in Nunez v. Morgan, 77 Cal. 427: “We cannot conceive that the rule held applicable to a complaint would be different when applied to a cross-complaint, and, applying the rule referred to to the cross-complaint, the averments in it are all that the law requires.” The question before us here was decided in that case, unless some difference exists between a cross-complaint and an answer as to pleading an agreement, and I know of none so far as the point before us is concerned. Nor can I see why the defendant should be required to plead more specifically in an answer, than he would have to do if he were setting out the same facts in a complaint, and this would be true whether his answer took the form of a cross-complaint or any other. The reason for the distinction claimed by plaintiff is stated in Case v. Barber, supra (cited with approval in Reinheimer v. Carter, supra), to be as follows: “ When the defendant pleads such an agreement in bar, he must plead it so as to make it appear to the court that an action will lie upon it, for he shall not take away the present action, and not give him another on the agreement pleaded.”
Bliss on Code Pleading, 354 a, states the rule of pleading as does plaintiff, and cites the Ohio case in support of it. The Ohio case is based on the rule as stated in Stephens on Pleading, 331, and this author goes back to the old case in T. Raymond, 450. The rule as stated by Mr. Chi tty has the same origin.
I cannot believe that the rule as claimed by plaintiff, even at common law, was well settled, but, whether so or not, it does not seem to rest upon reason, nor is it in harmony with the theory of code pleading.
It was held in Tucker v. Edwards, 7 Colo. 209, on demurrer to an answer setting up a defense relating to *209an agreement to convey land, but not stating that it was in writing, that it was not necessary to aver it to be in writing.
If we could assume that no such agreement as defendant alleges was made in writing, we might be justified in holding with plaintiff. But, as we hold that his answer is good, we must also assume that he will sustain it by competent evidence; and this brings us to notice the second point made by defendant.
2. Defendant next contends that it was not necessary that the agreement alleged should be in writing. On the other hand, plaintiff contends that the case clearly falls within the principle that, where parties have deliberately put their engagements into writing in such terms as import a legal obligation, without any uncertainty as to the object or extent of such engagement, it is conclusively presumed that the whole engagement of the parties and the extent and manner of their undertaking were reduced to writing. (Citing 1 Greenleaf on Evidence, sec. 275; Harrison v. McCormick, 89 Cal. 327; 23 Am. St. Rep. 469; Guy v. Bibend, 41 Cal. 322.) As the case must go back for trial, it is proper that this question should now be settled.
In Harrison v. McCormick, supra, it was declared that whether a writing is upon its face a complete expression of the agreement of the parties is one of law. That the agreement here was such a contract would seem to me quite obvious.
The collateral was by the terms -of the agreement to secure payment of the note—all of it—and interest; there was power given to sell and apply the proceeds to payment and pay to defendant any surplus. It was provided that if the securities deteriorated in value defendant should reduce the note in proportion to the deterioration. To prove by parol that plaintiff agreed to look only to the securities is wholly at variance with this latter clause, for, if that were true, defendant would never have agreed to keep the securities good in case of deterioration. Nothing is wanting in this assignment of these securi*210ties to make it a complete legal obligation, and it is to be presumed that the parties introduced every material item and term into it.
Defendant owed the full sum stated in this note; he agreed to pay that sum with interest; the bonds were given as security for payment, not as payment; to admit oral evidence to prove defendant’s contention would not only vary the agreement as to the collateral, but might also result in varying the terms of the note by oral proof of a contemporaneous agreement, and this it has been decided by this court cannot be done. (Guy v. Bibend, supra.)
Defendant insists that the agreement pleaded in defense is not inconsistent with or contradictory of any of the provisions of the agreement set out in the complaint, and therefore the answer sets up a good defense against a deficiency judgment, but he does not, either in his opening brief or in his reply brief, mention the point now before us. We hold with him that he was not obliged to plead a written agreement, but, if he cannot prove a written agreement to the effect pleaded, his defense will and should avail him nothing.
In Sivers v. Sivers, 97 Cal. 518, the instrument was silent as to the time of payment, and the court held it competent to show, by parol "that a period or event had been agreed upon between the parties thereto at which payment should be made.”
“The rule which excludes evidence affecting the terms of a written instrument does not apply when the parties have not incorporated into the instrument all of the terms of their agreement, and when the evidence offered or the agreement sought to be proved is not inconsistent with the terms embodied in the instrument.” But here we have a proposition, I think, to vary by parol a complete contract as to the collateral security, and possibly to change the terms of the note secured by it, for under it defendant might escape with less than full payment.
The case of Guidery v. Green, 95 Cal. 630, cited by *211defendant, was the case of a subsequent written agreement superseding a former written agreement, and does not apply here.
The agreement pleaded, I think, falls within the meaning of section 1698 of the Civil Code, reading: “A contract in writing may be altered by a contract in writing or by an executed oral agreement, and not otherwise.”
Defendant claims that this refers only to the evidence that may be adduced. But if it is thus restricted it will suffice to compel him to exhibit an agreement in writing. (Smith v. Taylor, 82 Cal. 533; Schurtz v. Romer, 82 Cal. 474; West Coast Lumber Co. v. Apfield, 86 Cal. 335; Nicholson v. Tarpey, 89 Cal. 617.) Nor is this case within the exceptions mentioned in section 1856 of the Code of Civil Procedure. (Beall v. Fisher, 95 Cal. 568.)
Section 1625 of the Civil Code provides as follows: “The execution of a contract in writing, whether the law requires it to be written or not, supersedes all the oral negotiations or stipulations concerning its matter which preceded or accompanied the execution of the instrument.”
Defendant says in his answer that the agreement pleaded by him was made “prior to and at the time of the making and delivery by him to plaintiff of the promissory note and the instrument in writing mentioned” (the agreement as to the collaterals).
For the purposes of this case we must presume that the defendant in his pleading had in mind a provision supplemental to or in alteration of the original contract, in writing. If he can prove such a provision in writing, I do not think he should be precluded from doing so without having first pleaded that it is in writing.
When plaintiff moved for judgment on the pleadings he admitted that all the averments of the answer were true. (McGown v. Ford, 107 Cal. 177, and cases there cited.)
My conclusion is, that the trial court erred in granting plaintiff’s motion for judgment on the pleadings, *212and it is recommended that the judgment be reversed and that a new trial be granted.
Britt, C., and Haynes, C., concurred.
Por the reasons given in the foregoing opinion the judgment is reversed and a new trial granted.
Harrison, J., Garoutte, J., Van Fleet, J.