The theory of a compulsory reference is that the legal questions involved are simple; that a long account needs to be examined; and that, when the facts touching the obligations of the parties are found, and the items of the account established, the proper judgment will be obvious. Section-1013, Code Civil Proc., accords with this theory. It provides for a compulsory reference “when the trial will require the examination of a long account on either side, and will not require the decision of difficult questions of law.” The same rule applies to equitable as to legal actions. Thayer v. McNaughton, 117 N. Y. 111, 22 N. E. Rep. 562. It is not enough that the case may, by possibility, involve the examination of a long account. Id. Items of damage which involve no accounting do not justify such a reference. Morrison v. Benthuysen, 103 N. Y. 675, 9 N. E. Rep. 180. The accounts to be examined must be the immediate object of the action or of the defense, and not the incidental or collateral object. Camp v. Ingersoll, 86 N. Y. 433; Kain v. Delano, 11 Abb. Pr. (N. S.) 29. Here the plaintiff seeks to foreclose two mechanics’ liens. He had a contract with the defendants, wherein he agreed to erect within a fixed time, for the pricé of $10,175, seven buildings, according to plans and specifications. After the time had expired, and before the buildings were completed, the defendants discharged the plaintiff, and forbade him to proceed any further, and they finished the buildings themselves. The plaintiff alleges that he was without fault, and the defendants allege a justification of his discharge, and counter-claim for damages for bad work and materials, for delay, for a substantial departure from the plans and specifications, and for their expense in completing the buildings. One of the liens filed is for $1,175, $1,000 of which the plaintiff alleges is a payment due him upon the certificate of the architect given pursuant to the contract. This is put in issue by the answer. The other lien filed is for the entire contract price, as upon a quantum meruit, less certain credits, and for $766.14 extra work. It is plain that the main question involved in this case is whether the plaintiff kept within the terms of his contract, or whether he was guilty of a breach of it. If the plaintiff kept within his contract, the counter-claims, which depend upon his breach of it, must fail. If the plaintiff substantially departed from the contract without the consent of the defendants it is difficult to see how he can recover at all, unless it be for the $1,000 included in the architect’s certificate. The greater part of the claims which the parties put in issue are not accounts in the ordinary acceptation of the term, but damages which each party claims to recover against the other because of an alleged breach of the agreement. The accounting, if any, will be.incidental to the main issues. The defendants are entitled to have the main issues tried by the court. The court, having determined them, can then send the accounting to a referee, if any should appear to be necessary. Code Civil Proc. § 1013. Order reversed, with $10 costs and disbursements, and motion denied, with $10 costs. All concur.