
286 N.W.2d 290 (1979)
ASK, INC., Plaintiff and Appellee,
v.
Albert WEGERLE and Ida Wegerle, Defendants and Appellants.
Civ. No. 9628.
Supreme Court of North Dakota.
November 28, 1979.
*291 Richard B. Thomas, Minot, for plaintiff and appellee.
Floyd B. Sperry of Sperry & Erickson, Bismarck, for defendants and appellants.
VANDE WALLE, Justice.
Albert and Ida Wegerle appeal from a judgment of the district court entered on March 7, 1979, which decreed that Ask, Inc., held a valid first lien upon certain real property owned by the Wegerles in Mercer County, North Dakota, and that Ask, Inc., was entitled to a money judgment against the Wegerles for a total of $9,704.68, including interest and costs. We reverse and remand.
In June of 1974 the parties had entered into a written contract whereby Ask, Inc., was to construct a house to be completed in 90 days for the Wegerles on real property located in Mercer County. The contract contained a description of the building that was to be erected for the agreed price of $51,905.53. A supplemental agreement was entered into on October 29, 1974, in which Ask, Inc., agreed to correct certain defects in the construction of the house and to give the Wegerles a credit totaling $500 on the contract price as settlement for the delay in construction and for defects in work done to that date. Ask, Inc., finished the construction of the house in November of 1975. The Wegerles by that time had made payments totaling $41,000 on the balance due under the contract, but they refused to pay any more because of alleged additional defects in the construction of the house.
The parties had also entered into an oral contract whereby Ask, Inc., was to install two 100-foot water lines in connection with the construction of the house for a total cost of $1,000. Ask, Inc., also finished this construction in November of 1975, but the Wegerles refused to pay the amount due under this contract, too.
Because the Wegerles refused to make further payment, Ask, Inc., took steps to perfect two mechanic's liens upon the property, one for the construction of the house and one for installation of the water lines. In March of 1977, written demands for payment and notices of intention to file mechanic's liens for labor, materials, and supplies contributed in the construction of the house and water lines were mailed to the Wegerles. The notices of intention to file mechanic's liens were also filed with the clerk of the district court for Mercer County. After waiting the fifteen days required by Section 35-27-11, N.D.C.C., Ask, Inc., filed mechanic's lien affidavits against the real property owned by the Wegerles. In June of 1977, Ask, Inc., served the Wegerles with a summons and complaint seeking foreclosure of its liens.
The Wegerles served an answer and counterclaim in which they alleged that the work was not completed as agreed but was defective and insufficient, and prayed for $25,000 to put the house in proper condition. They also alleged that because of the defective and improper filing of liens on the property they suffered severe stress and strain for which they sought money damages of $25,000. It was further alleged that Ask, Inc., acted with oppression and fraud in improperly constructing the house and in filing the liens, for which the Wegerles sought punitive damages in the sum of $10,000, plus costs and such other relief as might be awarded by the court. In their answer the Wegerles also made timely demand for a jury trial on the issues raised by their counterclaim. See Rule 38, N.D.R. Civ.P.
*292 Prior to trial Ask, Inc., moved, pursuant to Rule 39(a)(2), N.D.R.Civ.P., to strike the proceeding from the docket as a jury action because the proceeding was equitable, rather than legal, in nature. This motion was granted, we assume, because the case was tried without a jury. The denial of a jury trial on the issues raised in the counterclaim was one of the errors cited on appeal, although there is no record of the district court's striking the case from the jury term. The Wegerles' motion for summary judgment, based upon the alleged deficiency of the lien filings, was also denied by the district court.
The case came on for trial without a jury on January 4, 1979. On March 7, 1979, an amended judgment was entered granting Ask, Inc., a valid first lien upon the real property owned by the Wegerles and a total judgment of $9,704.68, including costs and interest. This amount was reached by allowing the Wegerles a setoff of $4,542.15 for defects in construction against the amount still owing under the contracts. The Wegerles have appealed from this judgment.
Several issues were raised by the Wegerles on appeal, but because of our disposition in the matter we need consider only the following:
1. Whether or not Ask, Inc., established valid mechanic's liens.
2. Whether or not the Wegerles should have had a jury trial on the issues raised by their counterclaim.

I
We consider first the validity of the mechanic's liens filed against the Wegerles' property for the amount still owing on the construction of the house and the water lines. The Wegerles contend that the liens were void in that Ask, Inc., had not complied with the requirement of Section 35-27-11(1), N.D.C.C.,[1] to keep an itemized account, nor had it complied with the requirement of Section 35-27-13, N.D.C.C.,[2] to file a true account of the demand for payment with the clerk of court.
This court, in the case of McCaull-Webster Elevator Co. v. Adams, 39 N.D. 259, 167 N.W. 330 (1918), held that whether a mechanic's lien has been properly filed or not is a question of fact, not law. As was noted by this court:
"It is true that in the filing of a mechanic's lien there must be an itemized statement of the account attached to the claim of lien, and there must also be a verification of the claim of the lien. A compliance with these requirements would have to exist before the lien could be filed. If there was no compliance with these requirements there would be no lien or proper claim of lien. Hence when the court found as a fact that the plaintiff made and filed in the office of the clerk of court a mechanic's lien it found that all the requirements of a mechanic's lien had been complied with, otherwise it would not have found it to be a mechanic's lien. It was not necessary for the court in its findings of fact to set out and show that each of the steps and requirements of law leading up to the acquiring and perfection of a mechanic's lien were complied with. This would be a cumbersome and unnecessary manner of stating the facts. When the court found that the plaintiff had made and filed its mechanic's lien it must have done so with full knowledge before it that all of the requirements of *293 law in regard to perfecting a mechanic's lien had been complied with. And the statement that the plaintiff had made and filed its mechanic's lien is therefore a statement of fact, and not a conclusion of law. The court found as a fact that the plaintiff had made and filed its mechanic's lien." 39 N.D. at 265, 167 N.W. at 331-332.
In the case at hand, it was found by the district court as a matter of fact that Ask, Inc., had complied with all the requirements of Chapter 35-27, N.D.C.C., in perfecting its mechanic's liens. Under N.D.R. Civ.P. 52(a), this court will not set aside a finding of fact unless it is shown that the lower court's finding is clearly erroneous. In Mattis v. Mattis, 274 N.W.2d 201 (N.D. 1979), we reiterated the rule established in prior decisions of this court that a finding of fact is clearly erroneous when, although there is some evidence to support it, the reviewing court on the entire evidence is left with the definite and firm conviction that a mistake has been made.
Looking at the evidence presented in this case pertaining to the liens, we find that Ask, Inc., filed the following statement with the mechanic's lien affidavit based on the house construction: ___________________________________________
C           STATEMENT OF ASK, INC.,
 O          126 Ninth Avenue Northwest,
  P         Minot, North Dakota
   Y
            Pete Steinke, officer and agent
         of Ask, Inc., of 126 Ninth Avenue
         Northwest, Minot, North Dakota, in
         the construction of residence at
         Hazen, North Dakota.
            Work Completed: November 11,
         1975
            Material, labor, and services furnished
         pursuant to contract:
         See attached contract
             Contract Price:        $51,405.53
             Less payment received   41,000.00
                                    __________
             Balance due on
               contract             $10,405.53
               plus interest from and since November
               11, 1975.
Ask, Inc., also filed a copy of the contract entered into by the parties which, in addition to other items, stated the agreed price and listed the following specifications:
C        A 30-50 ft. home with a 26-30 garage
 O       Built to specifications for Electric Heat
  P      Styro-foam lined Basement
   Y     Hip-Roof
         Triple Glazed Windows
         Oak doors and trim except in closets
           will be Hemlock
         Oak Holiday cabinets stain walnut
         Two-thousand dollar floor covering and
          counter top allowance
         Three hundred dollar light fixture allowance
         Owner to furnish own appliances
         Owner shall have Choice of exterior
          Color
         Interior shall be white
         Garage to Be Insulated & Finished,
          with Floor Drain
         Sewer System Adequate For the house
         Owner shall furnish water service to
          the water heater area in basement
         To be Started 10 days & Completed
          in 90 days
With the affidavit for the mechanic's lien based on the construction of the water lines, Ask, Inc., filed the following statement:
C           STATEMENT OF ASK, INC.,
 O          126 Ninth Avenue Northwest,
  P             Minot, North Dakota
   Y        Ask, Inc., contractor for Albert
         Wegerle and Ida Wegerle, Hazen,
         North Dakota, in the construction and
         installation of two (2) one hundred
         (100) foot water lines.
             Work Completed: November 11,
         1975
             Material, labor, and services furnished
         pursuant to contract described
         as follows:
              Material, supplies, and
               labor furnished in the
               installation of 2-100'
               water lines as per plans
               and specifications 
               agreed price              $1,000.00
              Less received on account     none
                                         _________
              Balance due                $1,000.00
               plus interest from and since
               November 11, 1975.
*294 The district court also had before it a 12-page itemized statement describing the materials used, their cost, the names and addresses of material suppliers, and labor expenses incurred in the construction of the house. This information had been provided the Wegerles in response to interrogatories and had been filed with the court.
After reviewing this evidence pertaining to the validity of the liens, we are not left with a definite and firm conviction that the district court was mistaken in finding that Ask, Inc., had complied with all the requirements of Chapter 35-27, N.D.C.C. We therefore affirm the district court's finding that Ask, Inc., held a valid first lien upon the property owned by the Wegerles.
We agree with the Wegerles that the accounts kept and filed by Ask, Inc., could have been clearer. But this does not mean that this court will or should reverse the district court's decision. In the case of Turner v. St. John, 8 N.D. 245, 78 N.W. 340 (1898), this court was faced with similar contentions that the lien statement did not contain a just and true account of the amount due. The case was before us for trial anew, and we held that the listing of the price agreed upon for each of the three separate contracts, properly designating each, along with the listing of 39 additional separate amounts and what each of them was for, less deductions for money already paid, was a sufficient statement of the accounts due. We quote:
"An `account,' under the statute referred to [Sec. 5476, Comp.Laws 1887],[3] is sufficient if it comes within the ordinary meaning of that term, or is one that is a fair and substantial compliance with the law. In the language of Gwin v. Waggoner, 98 Mo. 315, 11 S.W. 227,[4] relied upon by appellants, a just and true account, even when required to be itemized, means `a fairly-itemized account, showing what the materials are, and the work that was done, and the price charged, so that it can be seen from the face of the account that the law gives a lien therefor.'" 8 N.D. at 258, 78 N.W. at 344.
Because we no longer view the evidence anew under trial de novo, we rely more heavily on the findings of fact of the district court. But even under the standards established in Turner, supra, we find that the accounts filed and kept by Ask, Inc., are in fair and substantial compliance with the requirements of Section 35-27-11, subsection 1, N.D.C.C., and Section 35-27-13, N.D.C.C., and that the accounts on their face are sufficient for the granting of a lien.
Whether or not a particular account kept or filed in order to perfect a mechanic's lien meets the statutory requirements necessitates a consideration of the real-world situation from which the account arose. In considering the sufficiency of a lien statement, the South Dakota Supreme Court in Ringgenberg v. Wilmsmeyer, S.D., 253 N.W.2d 197 (1977), stated:
"It is true that such statement does not specifically itemize the number of rocks or amount of cement used to construct the rock facade. Neither does it detail the amount of labor performed and at what hourly wage. That does not dictate the invalidity of this particular statement, however. We should not decide *295 substantial compliance in a vacuum. Care should be taken to consider the nature of the business involved. Versa-Tech contracts to do an entire job based on their examination of the premises. This includes manufacturing, transporting, designing, and applying the stone and rock facade. There is no separate agreement made as to either material or labor; Versa-Tech sells a result at a certain price. In such instances it is not necessary, even if possible, to furnish further detail as to materials or labor. The information provided is sufficient to allow the owner to ascertain and verify the correctness of the lien. `Where the work is contracted for as an entirety for a specific amount, . . . all the information is given that is needed or can reasonably be required.'" 253 N.W.2d at 201.
But see Builders Supply Co., Inc. v. Carr, S.D., 276 N.W.2d 252 (1979).
Ask, Inc., like Versa-Tech in the South Dakota case, contracted to do an entire job for the Wegerles by providing both the labor and materials for the construction of a house and water lines. This was the result for which the parties contracted. There may be some question on the quality of the work done by Ask, Inc., but this does not detract from the fact that Ask, Inc., provided sufficient information to allow the Wegerles to ascertain the correctness of the liens upon their property.

II
We next consider whether the Wegerles should have been allowed a jury trial on the issues raised in their counterclaim. Generally, the right to trial by jury has been denied in equitable actions. Landers v. Goetz, 264 N.W.2d 459 (N.D.1978); C. I. T. Corporation v. Hetland, 143 N.W.2d 94 (N.D.1966); McCormack v. Phillips, 4 Dak. 506, 34 N.W. 39 (1887). This denial has been upheld even where the defendant has raised legal defenses. In C. I. T. Corporation v. Hetland, supra, this court reversed the judgment entered for the plaintiff for the balance due on a sales contract and remanded the case for a new trial so that the defendant could introduce evidence tending to prove failure of consideration; but because the action was for foreclosure of a lien and thus was an equitable action the district court's denial of the defendant's demand to have a jury consider the evidence was affirmed.
The defects in construction alleged by the Wegerles may show a failure of consideration similar to the situation in Hetland, supra, in which case this court could affirm the district court's denial of a jury trial based upon our holding in Hetland, supra, that the raising of affirmative legal defenses in equitable actions, such as the ones listed in N.D.R.Civ.P. 8(c), does not change an action from one triable before the court to one triable before a jury. But because the Wegerles have also raised legal issues in a counterclaim, we must consider whether or not the holding in Landers v. Goetz, supra, requires that we remand for a jury trial on the issues raised in that counterclaim.
Landers v. Goetz, supra, was a consolidated appeal of two actions involving the title and possession of three different tracts of real estate in the city of Bismarck. Landers's complaint alleged false representation as to certain real estate transactions. Goetz answered and counterclaimed, alleging fraudulent and oppressive actions on the part of Landers, and prayed for dismissal of the action, money damages, costs, and punitive damages. In her reply to the counterclaim Landers asked for dismissal of the counterclaim and demanded a jury trial. The district court denied Landers's demand for jury trial. This court reversed on appeal, holding that the district court had erred in denying this demand because the counterclaim had asked for relief which was legal, rather than equitable, in nature.[5]*296 The Wegerles have also raised legal issues in their counterclaim similar to the ones raised in Landers, supra. Because of this, we hold that the district court erred in denying the Wegerles a jury trial on the legal issues raised in their counterclaim.
In cases that present issues triable to both the court and a jury, the general rule is that legal issues entitling a person to a jury trial should be tried to a jury prior to the disposition of the equitable issues triable to the court. Whenever the issues are so interrelated that a decision in the nonjury portion might affect the decision of the jury portion, the jury portion is to be tried first; otherwise the party entitled to the jury trial on the legal issues would be deprived of part or all of his right to a jury trial. Landers v. Goetz, supra.
The judgment on the issues raised in the Wegerles' counterclaim must be set aside for the reasons stated above. These issues, which are for a jury, may be determinative, in whole or in part, of the issues raised in the complaint which were decided by the court. Although we hold that Ask, Inc., filed valid mechanic's liens, we must reverse the entire judgment and remand the matter to the district court for further proceedings, either by separate trial first on the jury issues, followed by an equitable determination of the amount owing, if any, on the liens, or by submission of all issues to the jury if so stipulated by the parties.
We must also vacate the award of costs to Ask, Inc., because the determination of who is the prevailing party in the action cannot be made until the remanded issues are determined.
The judgment is reversed and the case is remanded for further proceedings consistent with this opinion.
ERICKSTAD, C. J., and VANDE WALLE, PEDERSON, PAULSON and SAND, JJ., concur.
NOTES
[1]  Section 35-27-11, subsection 1, N.D.C.C., provides:

"No person shall be entitled to a lien under this chapter unless he shall:
"1. Keep an itemized account thereof separate and apart from all other items of account against purchaser; . . ."
[2]  Section 35-27-13, N.D.C.C., provides:

"Every person desiring to perfect his lien shall file with the clerk of the district court of the county in which the property to be charged with the lien is situated, within ninety days after all his contribution is done, and having complied with the provisions of this chapter, a true account of the demand due him after allowing all credits and containing a correct description of the property to be charged with a lien, which account shall be verified by affidavit."
[3]  Section 5476, Compiled Laws of the Territory of Dakota (1887), provided:

"Every person, except as has been provided for subcontractors, who wishes to avail himself of the provisions of this chapter, may file with the clerk of the district court of the county or judicial subdivision in which the building, erection or other improvement to be charged with the lien is situated, and within ninety days after all the things aforesaid shall have been furnished or the labor done, a just and true account of the demand due him after allowing all credits, and containing a correct description of the property to be charged with said lien, and verified by affidavit; but a failure to file the same within the time aforesaid shall not defeat the lien, except against purchasers, or incumbrancers in good faith, without notice, whose rights accrued after the ninety days and before any claim for the lien was filed."
[4]  This quotation was erroneously attributed to a case that appears on the same page. The correct citation is to Rude v. Mitchell, 97 Mo. 365, 11 S.W. 225, 227 (1889).
[5]  Landers, supra, cited Hetland, supra, as an example of an action in which this court held that there was no right to a jury trial because the action was equitable in nature. Ask, Inc., has relied upon Landers, supra, and Hetland, supra, for its contention that the Wegerles were not entitled to a jury trial on their counterclaim. The two cited cases are distinguishable in that no legal counterclaim was present in Hetland, supra. However, we do not conclude that a jury trial is required simply because a legal defense has been designated as a legal counterclaim.
