
30 Cal.App.3d 913 (1973)
106 Cal. Rptr. 696
CENTRAL BANK, Petitioner,
v.
THE SUPERIOR COURT OF KERN COUNTY, Respondent; R.P. RICHARDS, INC., et al., Real Parties in Interest.
Docket No. 1895.
Court of Appeals of California, Fifth District.
February 27, 1973.
*915 COUNSEL
Fitzsimmons & Hawthorne and Anthony W. Hawthorne for Petitioner.
No appearance for Respondent.
Hollister, Brace & Angle, George A. Rempe III and Robert O. Angle for Real Party in Interest R.P. Richards, Inc.
No appearance for other Real Parties in Interest.
OPINION
GARGANO, J.
Petitioner is a national banking association and a defendant in Kern County Superior Court action No. 120278. Real party (R.P. Richards, Inc.) is a licensed plumbing and heating contractor; it is the plaintiff in that action.
Real party's complaint in the superior court action contains four causes of action. The first cause of action is for unpaid labor and materials furnished on a building known as the Delano Hospital and seeks to foreclose a mechanics' lien on the property pursuant to the mechanics' liens law as set forth in part 4, division 3, title 14 of the Civil Code; as to this cause of action the plaintiff has alleged that petitioner was the lending institution on the Delano Hospital and that it claimed some interest in the property by virtue of its construction loan. The second cause of action is in common count and is directed against certain named defendants, other than petitioner. The third cause of action is on an open book account and, like the second cause, is not directed against petitioner. The fourth and final cause of action is directed against petitioner only, and is predicated on Civil Code sections 3159 and 3162 which are also a part of the mechanics' liens law of this state.[1]
*916 Petitioner has petitioned this court for a writ of mandate to compel the Kern County Superior Court to change the venue of the superior court action to Alameda County; petitioner's main office and principal place of business is located in Alameda County and the lower court denied its motion to change the venue of the action to that county. Petitioner argues that the change of venue is compelled by section 94 of title 12 of the United States Code. The section, a part of the National Bank Act, provides: "Actions and proceedings against any association under this chapter may be had in any district or Territorial court of the United States held within the district in which such association may be established, or in any State, county, or municipal court in the county or city in which said association is located having jurisdiction in similar cases." (12 U.S.C. § 94.)
Real party, on the other hand, contends that the mandatory provisions of section 94 have no application in this case because the superior court action is an action to foreclose a mechanics' lien and is local, not transitory, in nature. Real party contends, further, that by making a construction loan for a project located in Kern County the bank waived its right to have the lawsuit tried in Alameda County.[2]
(1) Ordinarily, a lawsuit involving a national bank must be tried in the county in which its main office is located even though the trial may cause serious inconvenience to numerous other defendants properly joined in the action; the venue provisions of section 94 are mandatory. (Mercantile Nat. Bank v. Langdeau (1963) 371 U.S. 555 [9 L.Ed.2d 523, 83 S.Ct. 520].) However, the United States Supreme Court has formulated two exceptions.
The first exception is articulated in the early case of Casey v. Adams (1880) 102 U.S. 66 [26 L.Ed. 52]. That case was concerned with a *917 mortgage foreclosure and the high court stated: "Local actions are in the nature of suits in rem, and are to be prosecuted where the thing on which they are founded is situated. To give the Act of Congress the construction now contended for, would be, in effect, to declare that a national bank could not be sued at all in a local action where the thing about which the suit was brought was not in the judicial district of the United States in which the bank was located. Such a result could never have been contemplated by Congress." (102 U.S. p. 68 [26 L.Ed. p. 53].)
The second exception was iterated in First National Bank of Charlotte v. Morgan (1889) 132 U.S. 141 [33 L.Ed. 282, 10 S.Ct. 37], and reiterated in Michigan Nat. Bank v. Robertson (1963) 372 U.S. 591 [9 L.Ed.2d 961, 83 S.Ct. 914]. In the first opinion the Supreme Court held that the venue provisions of the bank act, though mandatory, are not jurisdictional and are waived by implication if a national bank does not assert timely its right to be sued at its home county. In the second opinion the high court held that a waiver may arise out of contractual provisions between the parties; the cause was remanded to the state court for determination as to whether a waiver had occurred.
(2) An action to foreclose a mechanics' lien, like a mortgage foreclosure, is an in rem action and is local in nature; the plaintiff is resorting primarily to the security for the payment of the indebtedness (2 Witkin, Cal. Procedure (2d ed. 1970) Actions, § 424, p. 1255, § 429, p. 1259, § 435, p. 1263). (3a) But, when the first cause of action of plaintiff's complaint is considered in light of the second and third causes of action, the common count and the open book account, it is clear that real party does not seek, merely, to foreclose a mechanics' lien; real party's real objective is to recover a money judgment. In short, the first three causes of action of the complaint are based on the same transaction and when viewed as a whole demonstrate that real party is after a money judgment for labor and materials it furnished at the instance of some of the named defendants. (4) It is the rule that "where the main relief sought is personal, the fact that title or possession of real property is incidentally involved does not change its character as a transitory action." (2 Witkin, Cal. Procedure (2d ed. 1970) Actions, § 424, p. 1256.)
(3b) The fourth cause of action, albeit predicated on Civil Code sections 3159 and 3162 which are a part of the mechanics' liens law, is clearly transitory; real party seeks to recover funds allegedly allocated by petitioner to the Delano project and to hold petitioner independently liable for labor and materials real party furnished on that project if the bank disbursed any of the funds after it was served with a bonded stop *918 notice. (5) It is elementary that a plaintiff cannot deprive a defendant of his normal right to have a transitory action tried in the county of his residence by joining the transitory cause with a local cause of action. (2 Witkin, Cal. Procedure (2d ed. 1970) Actions, § 498, p. 1320.) If, under normal venue rules, a plaintiff cannot deprive a defendant of his normal right to have a transitory action tried in the county of defendant's residence by joining a transitory cause with a local cause, a fortiori, a plaintiff cannot circumvent the mandatory language of a federal enactment by joining local actions with transitory actions.
We compendiously dispose of real party's secondary argument that there was a waiver in this case. The theory of recovery of the fourth cause of action is that by virtue of the construction loan petitioner irrevocably committed sufficient funds to the Delano Hospital project to pay real party's claim and is independently liable to real party if it disbursed any funds to the borrowers after it was served with a bonded stop notice. Therefore, all records petitioner will need for its defense are, presumably, housed in its main office. (6) To hold that petitioner waived a substantial statutory right to be sued in Alameda County solely because it made a construction loan on a building located in another county of the same state would distort the plain and mandatory language of the federal statute. It would also ignore the very purpose for which the statute was enacted. As the United States Supreme Court observed in First National Bank of Charlotte v. Morgan, supra, 132 U.S. 141, 145 [33 L.Ed. 282, 284, 10 S.Ct. 37, 38-39], the federal law was enacted by the Congress for the convenience of national banking associations "to prevent interruption in their business that might result from their books being sent to distant counties in obedience to process from state courts."[3]
The cases which have found an implied waiver are cases in which there was extensive local activity. For example, in Helco, Inc. v. First National City Bank (D. Virgin Islands 1971) 333 F. Supp. 1289, the court found that a New York national bank had waived its venue rights when it advertised extensively in the Virgin Islands, competed with local banks, permitted customers to withdraw from and deposit in Virgin Island branch offices, solicited and accepted the protections afforded a local institution and involved itself in local fiscal affairs.
In Michigan Nat. Bank v. Superior Court (1972) 23 Cal. App.3d 1 [99 Cal. Rptr. 823], the lawsuit was for the conversion of an airplane, and the defendant was a national bank with its main office in Michigan. The airplane was purchased in California, it was to be housed in California, and all contractual documents were executed and were to be performed in *919 California. In addition, the national bank resorted to self-help in this state to enforce its security.
It is significant that the cases upon which real party relies to support its contention that petitioner waived the mandatory provisions of the federal statute are all cases in which the main office of the defendant national bank was located in a state other than the state in which the bank had conducted extensive business activities. We believe that there is a vast difference between the quantum of activity needed to warrant a finding of waiver as to a national bank which has conducted activities away from its home state and a national bank which conducts business in different counties of the same state. As Justice Black succinctly stated in his concurring opinion in Michigan Nat. Bank v. Robertson, supra, 372 U.S. 591, 595 [9 L.Ed.2d 961, 964, 83 S.Ct. 914, 916]: "I do not know of a single Act Congress has passed in a century which clearly and explicitly denies a person in one State the privilege of filing suit in his own State against an out-of-state company where service can be obtained and where the suit arises out of a transaction within the State. And I am not willing to find such a congressional purpose in § 94. I realize that this Court did hold several weeks ago in Mercantile Nat. Bank v. Langdeau, 371 U.S. 555, that this statute requires a suit in a state court against a national bank to be brought in the county where the bank is located. Langdeau merely required that the plaintiff sue in one county of the State rather than in another. Formal logic strictly applied might call for expansion of that holding to cover the different factual situation here. But that would require a plaintiff to go to another State hundreds of miles from home to bring suit for a wrong done him in a transaction in his own State, a result which I cannot believe Congress intended."
This is not, however, a situation in which the privilege sought to be asserted will compel suit in another state. Petitioner here seeks to have the suit brought in the county of this state specified by the federal statute, and on the facts of this case we find no waiver of the privilege.
Let a peremptory writ of mandate issue directing the Superior Court of Kern County to transfer Kern County Superior Court No. 120278 to Alameda County.
Brown (G.A.), P.J., and Franson, J., concurred.
On March 22, 1973, the opinion was modified to read as printed above.
NOTES
[1]  Section 3159 provides: "Any of the persons named in Sections 3110, 3111, and 3112, other than the original contractor, may, prior to the expiration of the period within which his claim of lien must be recorded under Chapter 2 (commencing with Section 3109), give to a construction lender a stop notice or a bonded stop notice unless a payment bond has previously been recorded in the office of the county recorder of the county where the site is located in accordance with Section 3235, except that the payment bond may be recorded at any time prior to the serving of the first stop notice. Such notice may only be given for materials, equipment, or services furnished, or labor performed. For the purposes of this section, where an owner undertakes construction on his own behalf, one who contracts with him for a portion of the work is a subcontractor and shall be entitled to give a stop notice."

Section 3162 provides: "Upon receipt of a stop notice pursuant to Section 3159, the construction lender may, and upon receipt of a bonded stop notice the construction lender shall, withhold from the borrower or other person to whom it or the owner may be obligated to make payments or advancement out of the construction fund, sufficient money to answer such claim and any claim of lien that may be recorded therefor, unless a payment bond has been recorded pursuant to the provisions of Section 3235 at any time prior to the serving of the first stop notice or bonded stop notice."
[2]  The record does not disclose whether petitioner has a branch office located in Kern County, and no contention has been made that such a branch office would justify retention of venue in Kern County. Since the question is not before us, we express no opinion as to whether a national banking association might be deemed to be "established" within the meaning of 12 United States Code, section 94 in a county where a branch office was located.
[3]  See footnote No. 2, supra.
