
    DIVERSIFIED MORTGAGE INVESTORS, Petitioner, v. LLOYD D. BLAYLOCK GENERAL CONTRACTOR, INC., et al., Respondents.
    No. B-6725.
    Supreme Court of Texas.
    Dec. 20, 1978.
    
      Saner, Jack, Sallinger & Nichols, T. Rick Frazier, Alfred Sallinger and H. Louis Nichols, Dallas, for petitioner.
    Smith, Smith, Dunlap & Canterbury, George C. Dunlap and Bowen L. Florsheim, Dallas, for respondents.
   SAM D. JOHNSON, Justice.

ON MOTION FOR REHEARING

We grant the motion for rehearing filed by DMI only insofar as it deals with that part of our previous opinion relating to the issue of equitable subrogation. We therefore set aside our former judgment, withdraw our former opinion, and substitute the following in its place.

This case requires determination of the relative priorities of mechanic’s and materi-alman’s liens, deed of trust liens, and a vendor’s lien to which the mortgagee may be equitably subrogated. Lloyd D. Blaylock General Contractor, Inc. and Lloyd D. Blay-lock, individually, (hereinafter collectively referred to as “Blaylock”) hold duly perfected mechanic’s liens on certain properties pursuant to a construction contract with Dollar Inns of America, Inc. (“Dollar Inns”) and K. R. Riley. Diversified Mortgage Investors (“DMI”) holds deed of trust liens on these properties through financing arrangements whereby it provided permanent financing to Dollar Inns for the purchase of land, the purchasing of a prior vendor’s lien, and the construction of two motels on these properties. All parties sought a declaration of the priorities of their claims. In addition, Blaylock sought to recover the balance due on the construction contract and to foreclose the mechanic’s liens on the properties. In the alternative, Blaylock sought the right to follow the proceeds of the deed of trust foreclosure sales to acquire payment of the construction contract. The trial court rendered judgment against Dollar Inns and Riley, holding them liable on the construction contract; however, the trial court ruled that Blaylock take nothing from DMI because the deed of trust liens were superior to the mechanic’s liens. The court of civil appeals reversed and rendered, holding that DMI’s deed of trust mortgages were superior to the mechanic’s liens only to the extent such mortgages secured the purchase money, not the construction loans. Furthermore, the intermediate court held that Blaylock could recover $204,776.29 from DMI out of the proceeds of the deed of trust foreclosure sales. 548 S.W.2d 924. We reverse the judgment of the court of civil appeals as to the Fort Worth property and affirm the judgment of the trial court. We modify the judgment of the court of civil appeals as to the Irving property and, as modified, such judgment is affirmed.

The liens involved in the instant case arise from the financing and construction of two Dollar Inns motels — one in Fort Worth and one in Irving. Although the facts are similar as to each location, the lien priorities must be determined independently for each piece of property; therefore, the facts relative to construction and financing on the two pieces of property will be discussed separately.

FORT WORTH PROPERTY

Construction:

In the fall of 1972 Blaylock and Dollar Inns began negotiations for construction of two motels. Thereafter, on December 29, 1972, Dollar Inns and Blaylock entered into a preliminary agreement whereby Blaylock agreed to construct motels on both the Fort Worth and Irving sites pursuant to a general construction contract to be executed at a later date. At this time, Dollar Inns further directed Blaylock to proceed with construction on the land as much as possible until the building permit could be obtained. Pursuant to such an agreement, subcontractors of Blaylock began subsurface investigation of the site on January 24, 1973. Such work involved the drilling of core bor-ings and analysis of the content of the soil. Thereafter, between January 25, 1973 and March 1, 1973, another subcontractor of Blaylock performed job site engineering and topographical survey work upon the site, which entailed the placing of various stakes and iron rods to locate drives, grades, and building sites upon the land. By March 1, 1973 approximately one hundred fifty stakes and eight iron rods were placed on the land and stood visibly one to three feet above the ground. During this period, on February 21,1973, Blaylock and Dollar Inns finalized their agreement in a written construction contract. On March 5, 1973 lumber for batter boards was delivered, and delivery of fill dirt was begun. Erection of the batter boards was begun on the same day as delivery and such work was completed by March 9, 1973. Batter boards are L-shaped structures which stand two feet off the ground and extend five feet in each direction. Such boards define the corners of the building and are preparatory to building the foundation. At the same time the batter boards were being erected, and continuing for approximately forty-five days, Blaylock began spread operations with the fill dirt being delivered. Such operations entailed the moving of dirt upon the land to prepare the ground for the foundation and the grading of the lot and involved six trucks and front-end loaders working on the property. Excavation for a retaining wall was also begun. As of March 9, 1973 all batter boards were erected, and a sign was placed at the job site indicating that construction of a Dollar Inns motel was in progress. Thereafter, on March 16, 1973, a building permit was obtained for the Fort Worth project. After the permit was received, foundation work was begun by a subcontractor of Blaylock. Such foundation work required the subcontractor to excavate for perimeter beans around the foundation and to lay the concrete foundation upon the dirt pad formed during the spread operations. After the completion of construction, on January 19, 1974, Blaylock filed its mechanic’s lien pursuant to Article 5453, Texas Revised Civil Statutes Annotated, to secure the unpaid portion of the construction contract relative to the Fort Worth project, amounting to $68,009.29.

Financing:

In November 1972 Dollar Inns began negotiations with DMI concerning permanent financing for the construction of two motels. Similar negotiations were conducted with Palomar Mortgage Investors in January 1973. On December 11, 1972 Dollar Inns, acting through K. R. Riley, contracted to purchase property in Fort Worth from J. M. Loffland, Jr., trustee. Under such contract of sale, Dollar Inns placed $5,000 earnest money in escrow. Later, Dollar Inns placed an additional $5,000 in escrow in order to extend the closing date beyond the January 15, 1975 closing date specified in the contract of sale. The $10,000 earnest money was later applied toward the total cost of closing. On February 16, 1973 Dollar Inns and Palomar executed a loan agreement by which Palomar agreed to provide interim financing for the purchase of the Fort Worth property and construction of a motel thereon. Palomar, in exchange for its funds, received Dollar Inns’ promissory note in the amount of $1,200,000 and secured the same through a deed of trust covering the Fort Worth property and improvements erected thereon. Such loan agreement incorporated by reference a commitment of DMI dated November 10, 1972 and a commitment of Palomar dated January 15, 1973. In such commitments and a tri-party agreement executed by Dollar Inns, DMI, and Palomar, it was agreed that Palomar would provide interim financing for the purchase of land and construction of the motel and that DMI would provide permanent financing after construction was completed. Thereafter, on March 8, 1973, Dollar Inns consummated the purchase of the Fort Worth property at a purchase price of $135,000. At that time the property was free and clear of any liens. Palomar, through the title company, paid Dollar Inns $598,352.45, $135,000 of which was used to purchase the Fort Worth property. On March 9, 1973 the deed of trust was filed and recorded. On February 5, 1974, after construction was completed on the Fort Worth motel, Palomar assigned its security interest in the Fort Worth motel and property, as well as to the Irving motel and property, to DMI for a total consideration of $2,757,150. After the assignment, Dollar Inns defaulted on its deed of trust. DMI foreclosed its deed of trust lien on the property with the motel located thereon and purchased the same at the foreclosure sale on December 3, 1974 for a price of $600,000.

IRVING PROPERTY

Construction:

As stated, Dollar Inns and Blaylock began negotiations concerning construction of two motels in the fall of 1972; they entered into a preliminary agreement on December 29, 1972 whereby Blaylock agreed to construct motels on both sites pursuant to a general construction contract to be executed at a later date. At this time, Dollar Inns directed Blaylock to proceed with construction on the land as much as possible until the building permit could be obtained. Thereafter, on January 25, 1973, wooden stakes were delivered to the property and topographical work and job site engineering were conducted, continuing until March 1, 1973. As a result of such work, the layout of the building was visibly staked on the property as of March 1, 1973. During this period, on February 21, 1973, Blaylock and Dollar Inns entered into a written construction agreement. On March 25,1973 lumber for the batter boards was delivered and erection of such batter boards began and was completed by April 2, 1973. On April 5, 1973 a subcontractor to Blaylock commenced general site clearance and excavation which included the removal of several large trees, the clearing of the land, and the removal of a swimming pool which had previously been located on the property. Also at this time fill dirt was delivered to the site and spreading operations were begun, involving truck haulers and a truck loader at the site. On April 7, 1973 concrete section pipe was delivered to the site. Thereafter, on April 11, 1973, a building permit was obtained and a subcontractor began work on the concrete foundation. Such foundation work required excavation for perimeter beams and the laying of the concrete foundation on the dirt pad formed by the spread operations. After construction of the motel was completed, on January 9, 1974, Blaylock filed his mechanic’s lien affidavit in accordance with Article 5453 to secure the unpaid portion of the construction contract relative to the Irving project, amounting to $136,767.

Financing:

As stated, as early as November 1972 Dollar Inns began negotiations with DMI and later, in January 1973, with Palomar Mortgage Investors concerning the financing for the purchase of land and construction of two motels. On January 18, 1973 Dollar Inns entered into a contract of sale with First Madison Corporation to purchase property in Irving, Texas. The total purchase price was $309,900, of which $200,000 was paid by Dollar Inns on January 18, 1973. On February 16, 1973 Dollar Inns and Palomar entered into a loan agreement wherein Palomar agreed to provide interim financing for the purchase of the Irving land and the construction of a motel thereon. Such loan agreement incorporated a previous commitment issued by Palomar dated January 15, 1973 and a commitment issued by DMI dated November 10, 1972. These commitments, in addition to a tri-party agreement executed by DMI, Palomar, and Dollar Inns, provided that interim financing was to be furnished by Palomar and that DMI agreed to provide permanent financing after completion of construction. Palomar, in exchange for its funds, received Dollar Inns’ promissory note in the amount of $1,665,000 and secured same through a deed of trust on the Irving property and improvements thereon. The closing of the sale of the Irving property to Dollar Inns was consummated on April 5, 1973 for a total purchase price of $309,900, of which $109,900 was used to pay off a prior vendor’s lien held on the land by First Bank and Trust of Richardson under a deed of trust dated July 26, 1972. As a result of the transaction, First Bank and Trust of Richardson executed a release of lien to the property. On April 12, 1973 the deed of trust on the Irving property was filed and such deed was recorded on April 13, 1973. On February 5, 1974, after completion of construction of the motel, Palomar assigned its interest in the deeds of trust to both the Fort Worth and the Irving properties to DMI for a total consideration of $2,757,150. Thereafter, Dollar Inns defaulted on its deed of trust and DMI conducted a foreclosure sale on the property under its deed of trust on December 3,1974. DMI purchased the property at such sale for a consideration of $1,200,000.

The instant suit was brought by Blaylock to recover the balance due under the construction contract, to foreclose the mechanic’s liens on the two properties, and to obtain an order of sale of the two properties. By amended petition, it further sought a declaration by the court that its mechanic’s liens were superior to the deed of trust liens on the properties and that DMI’s title to the two properties was burdened with the mechanic’s liens. In the event the court found that the mechanic’s liens were extinguished by the deed of trust foreclosures, Blaylock sought to recover the amount of the mechanic’s liens from the proceeds received by DMI at the foreclosure sales in excess of the purchase money loaned by Palomar, DMI’s assignor. DMI answered with a general denial and pleaded that the deed of trust liens against the properties were superior to the mechanic’s liens.

The trial court, in an interlocutory summary judgment on February 21,1975, ruled against Dollar Inns and K. R. Riley, holding them liable on the construction contract to Blaylock. This interlocutory judgment was later incorporated into the final judgment rendered on January 15,1976. Neither Dollar Inns nor Riley appealed the judgment to the court of civil appeals or to this court; accordingly the trial court judgment as to these parties is final. After rendering the interlocutory judgment, the trial court proceeded to conduct a non jury trial on the issues of priority of the mechanic’s liens and the deed of trust liens held by DMI. The trial court held that the deed of trust liens were superior to the mechanic’s liens; therefore, judgment was rendered that Blaylock take nothing against DMI. On appeal, the court of civil appear^ reversed the trial court. The court of civil appeals held that the mechanic’s liens had their inception prior to the deed of trust liens held by DMI. However, the intermediate court held that a purchase money lien on property is superior to a mechanic’s lien, regardless of the inception of the mechanic’s lien, because a mechanic’s lien cannot antedate ownership of the property. The court of civil appeals further noted that DMI’s deeds of trust secured both the purchase money and the construction loan funds and held that the deed of trust liens were senior only to the extent that they secured the purchase money loaned. Therefore, Blaylock could proceed against DMI to have its liens satisfied out of the foreclosure sales proceeds received by DMI, as mortgagee, in excess of the purchase money loaned by Palomar, DMI’s assignor. Both DMI and Blaylock have appealed, asserting that the court of civil appeals erred in its determination of the priority of the liens. DMI further urges that the intermediate court erred in its determination of the inception of the mechanic’s liens involved herein.

INCEPTION OF MECHANIC’S AND MATERIALMAN’S LIENS

As a general rule, a properly perfected mechanic’s lien “relates back” to a time referred to as the inception of the lien for the purpose of determining lien priorities. Therefore, the court of civil appeals held that the priority of the various liens involved in the instant case hinged upon the court’s determination of the inception of the mechanic’s liens held by Blaylock. In determining the inception of the mechanic’s liens, the court relied upon Section 2 of Article 5459, which provides:

“The time of the inception of the lien, as used in this article, shall mean the occurrence of the earliest of any one of the following events:
“(a) The actual commencement of construction of the improvements or the delivery of the material to the land upon which the improvements are to be located for use thereon for which the lien herein provided results, provided such commencement or material is actually visible from inspection of the land upon which the improvements are being made; . . ”

Subsections 2(b) and 2(c) further provide that the inception of the lien may be established by recordation of a written construction contract or recordation of an affidavit swearing to the existence of an oral contract for construction. However, in the instant case no party has contended that such a written construction agreement or affidavit was filed for the purposes of delineating the time of the inception of the liens. Therefore, determination of the inception of Blaylock’s mechanic’s liens depends upon this court’s construction of Article 5459, Section 2(a).

The court of civil appeals determined that the final proviso of Article 5459, Section 2(a), was controlling in determining the inception of a mechanic’s lien; this proviso states:

“[PJrovided such commencement or material is actually visible from inspection of the land upon which the improvements are being made; . . . ”

By placing its emphasis upon this clause, the court of civil appeals enunciated the following standard to be applied in determining the inception of the mechanic’s lien:

“Thus, we feel that the chief inquiry to be made by the courts is whether there was visibility of commencement of construction such that a person, upon inspection of the land, would be put on notice that construction work had commenced or, because of material delivered and resting on the land, work was to commence shortly thereafter.” 548 S.W.2d 924 at 931.

The intermediate court applied this “visibility” standard in determining that Blaylock’s mechanic’s liens on both the Fort Worth and Irving projects were incepted prior to the execution or recordation of the deeds of trust. The court of civil appeals determined that the staking, fill dirt, and batter boards were visible from an inspection of the land and would indicate that “construction of improvements” had commenced upon the land. The intermediate court further determined that the delivery of stakes, iron rods, concrete pipe, and lumber for batter boards constituted the visible “delivery of material” to the land. As such construction activities and delivery of material occurred prior to the execution and recordation of the deed of trust liens, the court of civil appeals held that Blaylock’s mechanic’s liens were incepted prior to the deed of trust liens held by DMI, as assignee of Palomar.

DMI urges that the court of civil appeals erred in relying solely upon a “visibility” standard in determining the inception of the mechanic’s liens. DMI maintains that Blaylock’s activities prior to execution and recordation of the deeds of trust were only preparatory and preliminary to construction and did not constitute “actual commencement of construction of the improvements” as required by Article 5459, Section 2(a). Furthermore, DMI contends that the material delivered to the sites prior to execution and recordation of the deeds of trust do not constitute “material” as that term is defined in the statutes relating to mechanic’s and materialman’s liens: specifically, Article 5452, Section 2(b), which defines “material” as those items “consumed in the direct prosecution” of construction or “incorporated in the work.” Therefore, DMI urges that Blaylock’s activities on the projects prior to execution and recordation of the deeds of trust were not of the necessary degree or character to delineate the inception of a mechanic’s lien.

This court does not place reliance solely upon a “visibility” standard to determine the inception of mechanic’s liens under Article 5459. Article 5459, when read in conjunction with the other statutes governing mechanic’s liens, clearly provides additional standards or conditions which must exist before a mechanic’s lien is incepted. Article 5459, Section 2(a), specifies two categories of activities which delineate the inception of a mechanic’s lien: (1) the actual commencement of construction of the improvements; or (2) the delivery of material to the land upon which the improvements are to be located. This court must construe these provisions of the statute in order to determine what types of activities these inception-creating categories entail.

Central to the construction of the phrase “commencement of construction of the improvements” is a definition of the term “improvement.” Under the Texas mechanic’s and materialman’s lien statutes, the term “improvement” is given an extended meaning, including more than a building, an addition to a building, or a fixture. Under Article 5452, “improvement” is defined as:

“The word ‘improvement’ as used herein shall be construed so as to also include: abutting sidewalks and streets and utilities therein; clearing, grubbing, draining or fencing of land; wells, cisterns, tanks, reservoirs or artificial lakes or pools made for supplying or storing water; all pumps, siphons, and windmills or other machinery or apparatus used for raising water for stock, domestic use or for irrigation purposes; and the planting of orchard trees, grubbing out of orchards and replacing trees, and pruning said orchard trees. . . . ”

Therefore, under the Texas statute, the term “improvement” has been expanded to encompass certain types of work or activity, as well as structures. Accordingly, the activities encompassed by the “commencement of construction” category is similarly enlarged. Where the activity defined as an “improvement” has been commenced or is being performed, such activity is sufficient to constitute commencement of construction of an improvement under Article 5459.

On the other hand, where a building or a structure is the principal “improvement” involved, the statutory provisions of Article 5459, Section 2(a), are less definitive in establishing the inception of the mechanic's lien. The issue becomes whether construction of the structure itself is necessary or whether on-site preparation for such construction is sufficient. The majority of other jurisdictions dealing with statutes with similar wording has held that preliminary or preparatory activities are not sufficient to constitute commencement of construction. Specifically, these courts have held that such preliminary work as staking, measuring, filling, or making test holes is insufficient to define the inception of the lien. New Hampshire Savings Bank v. Varner, 216 F. 721 (8th Cir. 1914), affirmed, 240 U.S. 617, 36 S.Ct. 409, 60 L.Ed. 828 (1916); Kiene v. Hodge, 90 Iowa 212, 57 N.W. 717 (1894); Rupp v. Earl H. Cline & Sons, Inc., 230 Md. 573, 188 A.2d 146 (1963); National Lumber Company v. Farmer & Son, Inc., 251 Minn. 100, 87 N.W.2d 32 (1957); North Shaker Boulevard Co. v. Harriman Nat. Bank, 22 Ohio App. 487, 153 N.E. 909 (1924); Annot., 1 A.L.R.3d 822. The majority of other jurisdictions has held that commencement of construction of a structure does not occur until there is a beginning of substantial excavation for or the laying of the foundations, footings, or bases of the new structure. Mortgage Associates, Inc. v. Monona Shores, Inc., 47 Wis.2d 171, 177 N.W.2d 340 (1970); Annot., 1 A.L.R.3d 822. Kiene v. Hodge, supra; Carr-Cullen Co. v. Deming, 176 Minn. 1, 222 N.W. 507 (1928); North Shaker Boulevard Co. v. Harriman Nat. Bank, supra. See also cases cited in Annot., 1 A.L.R.3d 822, 830-35.

It appears to this court that the approach taken by the majority of other jurisdictions is sound in that both the mechanic or mate-rialman and other lienholders will be best served by a definitive measure for lien inception, rather than the case-by-case analysis enumerated by the court of civil appeals in the instant case. Such a standard would be a valid interpretation of Article 5459, which requires the “actual commencement of construction of the improvements.” This court interprets the term “actual” as to require the placing of something of permanent value on the land, as opposed to preliminary or preparatory activities or structures. Therefore, under most circumstances, the commencement of construction of the improvements in the form of a building or a structure must entail the excavation for or the laying of the foundation. Accordingly, under the commencement of construction category in Article 5459, the inception of the mechanic’s and material-man’s lien occurs only when the activity: (1) is conducted on the land itself; (2) is visible upon the land; and (3) constitutes either (a) an activity which is defined as an improvement under the Texas statute or (b) the excavation for or the laying of the foundation of a building or a structure.

The second category of activities under Article 5459, Section 2(a), which can give rise to the inception of a mechanic’s lien is “the delivery of material to the land upon which the improvements are to be located.” Central to a construction of this category is the definition of the term “material” as used in the mechanic’s and mate-rialman’s lien statutes. “Material” is defined in Article 5452, Section 2 b, as follows:

“b. The words ‘material,’ ‘furnish material,’ or ‘material furnished’ as used in this Act are to be construed to mean any part or all of the following:
“(1) Material, machinery, fixtures or tools incorporated in the work, or consumed in the direct prosecution of the work, or ordered and delivered for such incorporation or such consumption. . . ”

Accordingly, under such a definition only the delivery of certain types of material will constitute the inception of a mechanic’s lien: specifically, either material which will be incorporated into the permanent structure or material which will be consumed or used up during the construction of the permanent structure. Therefore, in order for the delivery of material to constitute the inception of a lien, the court must find: (1) that there has been a delivery of material to the site of construction; (2) that such material is visible upon inspection of the land; and (3) that such material constitutes either (a) material which will be consumed during construction or (b) material which will be incorporated in the permanent structure.

The instant case must now be viewed under these standards and guidelines. The facts indicate that Blaylock’s activity on the Fort Worth project was insufficient to constitute commencement of construction or delivery of material prior to recordation of the deed of trust on March 9, 1973. The construction activities performed by Blaylock prior to March 9 consisted of the following: subsurface investigation, topographical survey work, the spreading of fill dirt, staking, erection of batter boards, excavation for a retaining wall, and erection of a sign. Such activities constitute merely preliminary or preparatory work for construction and do not constitute the actual commencement of construction. Actual construction began after March 16, 1973 when foundation work was begun on the property. Similarly, the material delivered to the site is not of the character to give rise to the inception of a lien. Such material included bundles of stakes and fill dirt. None of this material ultimately formed part of the permanent structure or was consumed in such construction, but was merely preliminary or preparatory material used prior to actual construction. Therefore, the inception of Blaylock’s mechanic’s lien on the Fort Worth project was after March 16, 1973 and after recordation of the deed of trust lien on the property held by DMI, as assignee of Palomar.

On the other hand, the work performed by Blaylock on the Irving project was sufficient to constitute the inception of a mechanic’s lien prior to the recordation of the deed of trust on April 13, 1973. At least three aspects of Blaylock’s activities on the Irving project were sufficient to constitute inception of the mechanic’s lien. First, a subcontractor to Blaylock performed excavation, clearing, and work in the nature of grubbing activity on the land commencing on April 5,1973. Such activity included: general site clearance, the digging up and removal of several large trees, and the digging up and removal of a swimming pool which was previously located on the site. This character of activity is encompassed under the expanded definition of “improvement,” which includes “clearing, grubbing, draining or fencing of land.” Therefore, as such clearing activity was performed on the Irving site, was visible upon inspection of the land, and was the performance of an activity included as an “improvement” under the mechanic’s lien statutes, it is sufficient to constitute inception of the mechanic’s lien as of April 5, 1973. In addition, affidavits and testimony indicate that concrete section pipe was delivered to the Irving site on April 7, 1973. Such material was to be incorporated in the permanent structure and was not material used for merely preparatory or preliminary activities. Therefore, as the concrete pipe was delivered to the site, was visible upon inspection of the site, and constitutes a material which will form part of the permanent structure, its delivery is sufficient to constitute inception of the lien on April 7, 1973. Finally, the trial court found that foundation work was begun on the property after April 11, 1973. The laying and excavation of a foundation clearly constitute commencement of the construction of an improvement under the standard enunciated by this court previously in this writing; therefore, such foundation work was sufficient to constitute inception of the lien on April 11,1973. Accordingly, the delivery of material and construction activity on the Irving project were sufficient to constitute inception of the mechanic’s lien prior to the April 13, 1973 recordation of the deed of trust held by DMI, as assignee of Palomar.

PRIORITY OF LIENS

Having determined the inception date of the mechanic’s liens relative to the recordation of the deed of trust liens, this court must now determine the priorities of such liens. The court of civil appeals determined that regardless of the inception date of the mechanic’s liens, a purchase money lien has priority. The court of civil appeals relied upon Irving Lumber Company v. Alltex Mortgage Company, 468 S.W.2d 341 (Tex.1971), which the intermediate court interpreted as holding:

“[WJhere a purchase money deed of trust was executed contemporaneously with the vesting of title in the mortgagor, then the purchase money deed of trust lien would have priority over a mechanic’s lien since the title of the mortgagor was burdened instantly with the purchase money deed of trust lien before the mechanic’s lien attached to the mortgagor’s title.” 548 S.W.2d 924 at 932.

However, the court of civil appeals restricted the priority of the deed of trust liens such that they were superior only to the extent of the purchase money loaned on the properties. The intermediate court followed the rule that a lien is impressed with the character of the debt it is given to secure. National Western Life Insurance Co. v. Acreman, 415 S.W.2d 265 (Tex.Civ.App.—Beaumont 1967), modified, 425 S.W.2d 815 (Tex.1968); C. D. Shamburger Lumber Co. v. Holbert, 34 S.W.2d 614 (Tex.Civ.App.—Amarillo 1931, no writ); Thompson v. Litwood Oil & Supply Co., 287 S.W. 279 (Tex.Civ.App.—Waco 1926, no writ). Therefore, it held that the deed of trust liens held by DMI were impressed with the character of both a purchase money mortgage lien and a construction loan mortgage lien. The court of civil appeals, therefore, determined that the portion of the deed of trust liens which secured the construction loan was not superior to a mechanic’s lien incepted prior to such deed of trust. The court of civil appeals further held that although the foreclosure sales extinguished all inferior liens on the properties, Blaylock was entitled to pursue a portion of the proceeds of the foreclosure sales in the hands of DMI, relying upon Habitat, Inc. v. McKanna, 523 S.W.2d 787 (Tex.Civ.App.—Eastland 1974, no writ).

Under Article 5459, a properly perfected mechanic’s lien has priority over all other liens, encumbrances, or mortgages upon the land. However, Article 5459 further states that such mechanic’s liens will not affect liens, encumbrances, or mortgages on the land at the time of inception of the mechanic’s lien. Specifically, Article 5459 provides:

“Section 1. The lien herein provided for shall attach to the house, building, improvements or railroad for which they were furnished or the work was done, in preference to any prior lien or encumbrance or mortgage upon the land upon which the houses, buildings or improvements, or railroad have been put, or labor performed, and the person enforcing the same may have such house, building or improvement, or any piece of the railroad property, sold separately; provided, any lien, encumbrance or mortgage on the land or improvement at the time of the inception of the lien herein provided for shall not be affected thereby, and holders of such liens need not be made parties in suits to foreclose liens herein provided for.”

Article 5459 was amended in 1971 in reaction to the first opinion rendered in Irving Lumber Company v. Alltex Mortgage Com pany, 14 Tex.Sup.Ct.J. 212 (July 2, 1971), which allowed oral construction contracts to indicate the inception of a mechanic’s lien thereby in effect allowing the creation of silent or secret mechanic’s liens. Therefore, the amendment to Article 5459 was aimed at defining “inception of a lien” and created the system whereby mortgagors could rely upon notice in the county records or by visual inspection of the property as to any existing liens on the property. The first opinion in Irving Lumber Company was withdrawn on motion for rehearing and the second opinion substituted. The second opinion did not deal with the issue of secret mechanic’s liens, but rather dealt with the issue of attachment and priority of mechanic’s liens. In the second opinion the court held that a mechanic’s lien must attach to the interest of the person contracting for construction; where such person owns no interest in the property, there is no interest to which the mechanic’s lien may attach. Accordingly, such lien could not attach until the person contracting with the mechanic or the materialman owned an interest in the land, which in Irving Lumber was at the time of purchase.

Our courts have long held that a mechanic’s and materialman’s lien attaches to the interest of the person contracting for construction. Thus, if a lessee contracts for construction, the mechanic’s lien attaches only to the leasehold interest, not to the fee interest of the lessor. Grube v. Nick’s No. 2, 278 S.W.2d 252 (Tex.Civ.App.—El Paso 1955, writ ref’d n. r. e.); Penfield v. Harris, 7 Tex.Civ.App. 659, 27 S.W. 762 (Tex.Civ.App.1894, writ ref’d). Similarly, the courts have held that a mechanic’s lien may attach to an equitable interest of one holding an option on land, but that such lien is extinguished if the fee is not obtained by the optionee. Kelly v. Heimer, 312 S.W.2d 430 (Tex.Civ.App.—San Antonio 1958, writ ref’d n. r. e.). It should be noted that there is also a line of Texas cases which holds that mere contemplation of acquisition of title is sufficient for attachment of the mechanic’s lien. Breckenridge City Club v. Hardin, 253 S.W. 873 (Tex.Civ.App.—Fort Worth 1923, no writ); Schultze v. Alamo Ice & Brewing Co., 2 Tex.Civ.App. 236, 21 S.W. 160 (1893). However, the majority of jurisdictions and the better rule generally require that the person contracting with a mechanic or a materialman must have some interest in the property either legal or equitable upon which the lien may attach. Sebastian Building & Loan Ass’n v. Minten, 181 Ark. 700, 27 S.W.2d 1011 (1930); Mansfield Lumber Co. v. Gravette, 177 Ark. 31, 5 S.W.2d 726 (1928); Sontag v. Abbott, 140 Colo. 351, 344 P.2d 961 (1959); Society Linnea v. Wilbois, 113 N.W.2d 603 (Iowa 1962); Wayne Building & Loan Co. of Wooster v. Yarborough, 228 N.E.2d 841 (Ohio 1967); and Paget v. Peters, 133 Or. 608, 286 P. 983 (1930). Proceeding on this principle, the majority of the courts generally applies the doctrine of “after-acquired title” or the “relation back” doctrine. These doctrines hold that the lien attaches to whatever legal or equitable interest the contracting party had when the work was begun, and thereafter attaches to any other or greater interest whenever acquired before the lien is enforced: provided that the after-acquired title enlarges an estate or interest to which the lien has already become attached. Jones v. Mawson-Peterson Lumber Co., 112 Colo. 493, 150 P.2d 795 (1944); Service Lumber & Supply Co. v. Cox, 98 Fla. 40, 123 So. 820 (1929); Paget v. Peters, supra. See also Annot., 52 A.L.R. 693. Accordingly, the priority of a mechanic’s lien not only depends upon the inception of the lien, but also upon whether the party contracting with the mechanic or the materialman has a legal or equitable interest in the property at the time of contracting.

In the instant case this court found that the inception of the mechanic’s lien on the Fort Worth property was not prior to the March 9,1973 recordation of the deed of trust held by DMI. As a consequence, under Article 5459, all liens or mortgages existing upon the land prior to the time of the inception of the mechanic’s lien do not become subordinate to such mechanic’s lien. Therefore, DMI’s deed of trust lien, both as to the purchase money mortgage and the construction loan mortgage, is superior and senior to Blaylock’s mechanic’s lien on the Fort Worth property. Accordingly, the foreclosure sale of the senior lien extinguished the junior lien, Irving Lumber Company v. Alltex Mortgage Company, supra.

On the other hand, this court has determined that the inception of Blaylock’s mechanic’s lien on the Irving site was prior to the April 13, 1973 recordation of DMI’s deed of trust on such property. To further determine the priority of the mechanic’s lien, this court must decide whether Dollar Inns, the party contracting with Blaylock, held any legal or equitable interest in the property at the time of inception of this mechanic’s lien. Dollar Inns, on January 18, 1973, prior to the inception of the mechanic’s lien, had executed a contract to purchase the Irving property from First Madison Corporation. Pursuant to such contract, Dollar Inns paid First Madison Corporation $200,000. Therefore, at the time of inception of Blaylock’s mechanic’s lien, Dollar Inns held an equitable right or interest in the land under a contract of purchase to which such mechanic’s lien could attach. Under the doctrine of after-acquired title, the security for such mechanic’s lien was later expanded to include the legal title to the property acquired by Dollar Inns when the sale was consummated on April 5, 1973 for a total price of $309,900. Accordingly, in the instant case the date of the inception of the mechanic’s lien and the date of attachment of such lien are concurrent. This is distinct from the fact situation in Irving Lumber Company wherein the date of inception of the mechanic’s lien arose prior to the attachment of such lien. In the instant case where there exist concurrent dates of inception and attachment of the mechanic’s lien, the date of inception of the mechanic’s lien will determine its priority over other liens. The date of inception of the mechanic’s lien preceded both the execution and recordation of DMI’s deed of trust lien on the Irving property; therefore, if there was no other factor involved, such mechanic’s lien would be senior and superior.

There is an additional factor, however, and that is the doctrine of equitable subrogation. It will be remembered that First Bank and Trust of Richardson held a vendor’s lien on the Irving property under a July 26, 1972 deed of trust. This vendor’s lien preceded any interest of any of the parties to this action. At the April 15,1973 closing of the sale of the Irving property, this lien was purchased by Dollar Inns with funds provided by Palomar for $109,900. At such time, First Bank and Trust of Richardson executed a release of the lien. Palomar, in exchange for its funds, received Dollar Inns’ promissory note in the amount of $1,665,000, which was secured through a deed of trust on the Irving property and improvements thereon. These funds covered both the purchase price and construction costs on the Irving site. Later, Palomar assigned all of its interest in the deeds of trust to DMI. Under these facts both the trial court and the court of civil appeals found that DMI was equitably subrogated to the vendor’s lien rights of First Bank and Trust of Richardson. We are in accord with this determination.

As long ago as 1895 this court recognized the favorable view afforded the doctrine of equitable subrogation. As stated in Faires v. Cockrill, 88 Tex. 428, 31 S.W. 190, 194 (1895):

“Perhaps the courts of no state have gone further in applying the doctrine of subro-gation than has the court of this state, of which we cite a few instances. One who discharges the vendor’s lien upon lands— even the homestead, — either by paying as surety, or at the request of the debtor, or at a judicial sale, which, for irregularities in the process, fails to convey the title, is entitled to be subrogated to the lien of the creditor to the extent of the payment so made.” [Citations omitted.]

We recognize the importance of this doctrine to lenders in this state. It serves to protect a lienholder from intervening liens, at least to the amount of the initial lien, when the lienholder has discharged a prior superior lien.

It might be argued that the doctrine of after-acquired title as enunciated in this opinion should serve to establish the priority of Blaylock’s lien. It might be asserted that since Blaylock’s lien incepted and attached at a time when Dollar Inns had an equitable interest in the land (by virtue of its contract of sale), the Blaylock lien should be expanded to include the subsequently acquired legal interest free from the burdens of DMI’s liens. The flaw in this reasoning is that First Bank and Trust of Richardson’s vendor’s lien existed prior to the time of either Dollar Inns’ equitable or legal interest in the land. To borrow from another decision by this court:

“By virtue of its subrogation to the first lien, [DMI] occupied the same position as [First Bank] with respect to that lien. Its deed of trust did not create an entirely new lien but preserved the existing lien and prescribed new terms and conditions for foreclosure.” Providence Insti-tntion for Savings v. Sims, 441 S.W.2d 516, 520 (Tex.1969).

If Blaylock is to reap the benefits of Dollar Inns’ subsequently acquired legal title, then it must also accept the burdens on that title; specifically, the preexisting vendor’s lien held by First Bank and Trust of Richardson.

To put the matter more clearly, let us suppose that at the time of closing on the Irving property Dollar Inns had not purchased and the Richardson bank had not sold and released its vendor’s lien. This would result in the Richardson bank holding a vendor’s lien, Blaylock having a mechanic’s and materialman’s lien, and DMI having a deed of trust lien. Under those circumstances, it could not be doubted but that the Richardson bank would hold the senior lien, superior to both Blaylock’s and DMI’s liens. That being the case, it also cannot be gainsaid that DMI stepped into the shoes of the Richardson bank, at least to the extent of the Richardson bank’s lien, by virtue of the doctrine of equitable subrogation. By foreclosing its deed of trust lien, DMI foreclosed the preexisting vendor’s lien secured thereby and it may now assert the priority of the bank’s lien.

The result of this holding is that the liens stand in the following order of priority: (1) the Richardson bank’s vendor’s lien in the amount of $109,900, to which DMI was sub-rogated ; (2) Blaylock’s mechanic’s lien in the amount of $136,767; and (3) the balance due on the note secured by the deed of trust held by DMI. The fundamental essence of this holding is that all proceeds received at the foreclosure sale of December 3, 1974 in excess of $109,900 (the extent of DMI’s subrogation) were excess proceeds. It will be recalled that the Irving property sold at the foreclosure sale for the sum of $1,200,-000. The total amount of consideration received by DMI in excess of the preexisting vendor’s lien to which it is subrogated was thus $1,090,100. The unpaid portion of the construction contract relative to the Irving property was $136,767. Under these circumstances, we are squarely faced with the precise question on which this court reserved judgment in Irving Lumber Company, supra: whether Blaylock may pursue the excess proceeds of the foreclosure sale. We agree with the court of civil appeals’ holding that Blaylock may pursue the excess proceeds. See L. M. Sullivan Co. v. Essex Broadway Sav. Bank, 380 A.2d 1087 (N.H.1977); New Jersey Building, Loan & Investment Co. v. Bachelor, 54 N.J.Eq. 600, 35 A. 745 (1896). See also East Atlanta Bank v. Limbert, 191 Ga. 486, 12 S.E.2d 865 (1941); Boeschenstein v. Burde, 284 S.W. 202 (Mo.App.1926). See generally Westinghouse Elec. Co. v. Vann Realty Co., 568 S.W.2d 777 (Mo.1978). This is the logical result inasmuch as DMI’s right of subrogation extends only to the amount of the preexisting vendor’s lien. See W. C. Belcher Land Mortgage Co. v. Taylor, 212 S.W. 647 (Tex.Com.App.—1919, jdgmt. adopted).

In summary, this court holds that DMI’s deed of trust lien on the Port Worth property was senior and superior to Blaylock’s mechanic’s lien; therefore, the deed of trust foreclosure extinguished the junior mechanic’s lien. As to the Irving property, DMI’s deed of trust lien is senior and superior to Blaylock’s mechanic’s lien only to the extent of the Richardson bank’s preexisting vendor’s lien in the sum of $109,900. Beyond that amount, Blaylock has a valid and subsisting lien in the amount of $136,767; however, the sale by the trustee under the deed of trust transferred the land itself free of all liens; therefore, Blaylock’s security interest has transferred to the excess proceeds from the sale, which stand in the place of the property and may be reached by Blaylock. Jeffrey v. Bond, 509 S.W.2d 563 (Tex.1974); Pearson v. Teddlie, 235 S.W.2d 757 (Tex.Civ.App.—Eastland 1950, no writ). Whatever remains thereafter goes to DMI on the balance due on the note. Since DMI bid in the land at its own foreclosure sale, no cash actually changed hands. Instead, DMI took title to the land in cancellation of part of the loan. Consequently, we are of the opinion that the court of civil appeals correctly determined that Blaylock’s proper remedy was in the form of money judgment against DMI for the unpaid amount of its lien on the Irving property. Habitat, Inc. v. McKanna, supra; L. M. Sullivan Co. v. Essex Broadway Sav. Bank, supra.

The judgment of the court of civil appeals relative to the Fort Worth property is reversed and the judgment of the trial court is affirmed. The cause of action relative to the Irving property is severed. As severed, the judgment of the court of civil appeals relative thereto is modified to allow Blaylock to recover a judgment against DMI in the amount of $136,767. As modified, such judgment is affirmed. 
      
      . The parties stipulated that K. R. Riley executed the contract on behalf of and as nominee for Dollar Inns of America, Inc.
     
      
      . The $598,352.45 paid to Dollar Inns by Palomar at the time of closing was advanced to cover both the purchase price of the Fort Worth property and the Irving property. The combined purchase price of the properties was $434,900. The remainder of the loan proceeds advanced was to be used toward construction of the motels. The record does not indicate when if ever Dollars Inns received the balance of the loan; however, the court of civil appeals held:
      “These instruments [checks representing purchase money, loan agreements, promissory notes, and deeds of trust], together with the fact that the motels were completed, gives us no hesitancy in finding, as the trial court did, that Palomar at the closings advanced the purchase money and, according to the loan agreements, made periodic advancements of the entire loan proceeds as the construction of the motels progressed and was completed stage by stage.” 548 S.W.2d 924 at 934.
     
      
      . See footnote 2 concerning advancement of funds by Palomar to Dollar Inns to cover purchase price and additional construction costs.
     
      
      . Article 5452, Section 2b, states:
      “b. The words ‘material,’ ‘furnish material,’ or ‘material furnished’ as used in this Act are to be construed to mean any part or all of the following:
      “(1) Material, machinery, fixtures or tools incorporated in the work, or consumed in the direct prosecution of the work, or ordered and delivered for such incorporation or such consumption. . . . ”
     
      
      . Irving Lumber Company v. Alltex Mortgage Company, 14 Tex.Sup.Ct.J. 212, was first rendered on July 2, 1971. In reaction to the first opinion, the 62d Legislature drafted Senate Bill 733; the Bill Analysis to Senate Bill 733, prepared March 22, 1971, indicated that the purpose of the Bill was:
      “To amend Article 5459, VTCS, to define the term ‘time of inception of a lien’ to clarify when the lien or [sic] the land attaches.”
      The Bill was passed and became immediately effective on May 17, 1971 under an emergency clause, which provided:
      “Sec. 2. The importance of this legislation and the crowded condition of the calendars in both Houses and the problems and confusion created by the Texas Supreme Court’s recent decision in the case of Irving Lumber Company v. AUtex Mortgage Company create an emergency and an imperative public necessity that the Constitutional Rule requiring bills to be read on three several days in each House be suspended, and this Rule is hereby suspended; and this Act shall take effect and be in force from and after its passage, and it is so enacted.” 1971 Tex.Sess.Law Serv., ch. 231, § 1, at 1082 (Vernon). [Emphasis added.]
      Simultaneous to the Legislature’s action, the Supreme Court was considering the motion for rehearing in Irving Lumber. Pursuant to such motion, the court withdrew the first opinion and substituted the second opinion on May 19, 1971, recorded at 468 S.W.2d 341. The second opinion does not construe or refer in any way to the amendment to Article 5459.
     
      
      . “Whether Irving was then entitled to pursue a portion of the proceeds of the sale in the hands of Alltex is not raised in this case . . .” 468 S.W.2d 341 at 344.
     