
    [S. F. No. 6932.
    Department Two.
    July 26, 1916.]
    ANDREW HERDAL, Appellant, v. MINNIE SHEEHY, Substituted in the Place of William J. Sheehy, Deceased, Respondent.
    Building Contract—Erection on Wrong Location—Excuse of Performance—Pleading.—A contractor for the erection of a building on a specified tract of land belonging to the owner, who erects it partly on such land and partly on an adjacent public street, cannot, in an action to foreclose a lien on the land, take advantage of an excuse for performance according to the terms of the contract, where his complaint declares on the theory of full performance. To render such excuse available to him, the complaint must aver both the failure of complete performance and the excuse.
    Td.—Contractor Must Bear Loss.—Where such mistake in the location of the building was in no way attributable to the owner, the contractor must bear the resulting loss.
    APPEAL from a judgment of the Superior Court of the City and County of San Francisco, and from an order refusing a new trial. James M. Troutt, Judge.
    The facts are stated in the opinion of the court.
    Stafford & Stafford, for Appellant.
    Cullinan & Hickey, for Respondent.
   MELVIN, J.

Plaintiff appeals from the judgment and from an order denying his motion for a new trial.

The action was one for the foreclosing of a lien upon real property in the city and county of San Francisco. Defend-, ant did not dispute the following facts: William J. Sheehy, her predecessor in interest, entered into a contract with plaintiff’s assignors according to the terms of which they were to erect a building upon his land. The contract price was $3,565, payable in four installments. W. J. Sheehy filed and recorded a written acceptance of the building on March 8, 1910. All of the contract price was paid to plaintiff’s assignors except $660, the amount for which their lien was filed. The foregoing facts are not disputed, but the defense to the action was based upon the' fact, found by the court, that the contractors, contrary to their written agreement with Mr. Sheehy, had erected the building partly upon his land and partly upon an adjacent public street. The court found that the defense was a good one, and that the building had not been located in compliance with the terms of the contract because it was not entirely upon the property of William J. Sheehy. There was a further finding that when the formal acceptance was filed this error in the location of the building was unknown to Mr. Sheehy, and that he did not waive the failure of the contractors to comply with the terms of their agreement.

Plaintiff had included in his complaint a count in quantum meruit, and upon the issue joined on this cause of action the court found that the reasonable value of the work done and materials furnished was less than the amount actually paid under the contract.

Appellant does not question the finding that the building was partly upon public property. His theory is that an independent contractor prepared the foundations for the building, and that in the execution of their contract for the erection of the superstructure plaintiff’s assignors did nothing more than follow the directions of Mr. Sheehy to use said erroneously located foundations.

Even conceding the status of the builder of the foundations as an independent contractor (although he was paid by the contractors out of the moneys received by them on account of the contract price), plaintiff did not plead failure of complete performance, excused by the mistake in the location of the foundations, but on the contrary he declared on the theory of full compliance by the contractors with the terms of the written agreement. The lot upon which the building was to be erected was particularly described in the contract. Clearly, the placing of the building partly upon other land was not a compliance with the agreement. If appellant relied upon Mr. Sheehy’s conduct as an excuse for nonperformance he should have set up both the nonperformance and the excuse. This he failed to do and he may not take advantage of it without pleading. (Daley v. Russ, 86 Cal. 114, [24 Pac. 867].) Appellant denies the application of this doctrine to building contracts because the courts have held that equity will always give judgment in suits on such contracts if there has been substantial performance, deducting from the price the damage on account of defects, citing in this behalf Marchant v. Hayes, 117 Cal. 669-672, [49 Pac. 840]. It is true that in the opinion in that case it is said, arguendo, that:

“It has been sometimes held that where a contractor under a bona fide attempt to perform his contract has unintentionally omitted some trifling particular, he may recover upon the contract, making a reduction for the damage sustained by the omission.” But the general rule is emphatically stated in the opinion. It is that one who has acted by virtue of a written contract has no right of recovery unless he can show that he had completed the contract on his part or that completion had been waived or excused. In this case appellant failed to show substantial compliance with the contract, and he did not plead excuse for his failure to build the house upon the property specified in the contract.

But eliminating all questions of pleading and giving plaintiff the benefit of every equitable right, we cannot see that the trial court committed error. It is not asserted that Mr. Sheehy intentionally misled the builders nor that Hegvold, who constructed the foundations, was intentionally at fault or that he was ever aware of his blunders. The contract specified that the structure was to be upon Mr. Sheehy’s lot, not that it was to be erected upon certain prepared foundations. The court found that the cost to Mrs. Sheehy to correct the fault in construction would be more than $660, the amount claimed by plaintiff. Manifestly it would be unfair to compel the innocent owner to pay the contract price, and then a large sum to have the building moved onto her lot and to allow the assignee of the builders to collect the full contract price for a building not in compliance with the plain terms of the written agreement. Mr. Sheehy and the builders were innocent of intentional wrong, but the latter were violators of substantial terms of the contract and should therefore be the sufferers, rather than the present owner of the land.

The judgment and order are affirmed.

Henshaw, J., and Lorigan, J., concurred.

Hearing in Bank denied.  