Deemer, C. J.
— The facts in the case are so complicated that we find it difficult to make a succinct statement. Only those questions which arise in the case of Findley, receiver, against the live-stock company, et al., defendants, and Richards, executor, appellant, are argued by appellant, and the other cases will be referred to only in so far as they are material to the issues presented.
1. For many years prior to the institution of this litigation, the Osceola Bank was a corporation doing a banking business in Clarke county, Iowa. George H. Cowles was vice president and manager, and C. W. Cowles, until shortly before the failure of the bank was one of its largest stockholders. On' the twenty-second day of November, 1888, the bank failed and was placed in the hands of a receiver. Prior to that time it had been a depository of county funds, and George H. and C. W. Cowles were sureties on the bond given by the bank to the county. A few days before the failure, G. H. Cowles deposited with the treasurer of the county about ten thousand dollars in bills receivable, as additional security to the county. In January of the year 1889 the county treasurer brought suit on the bond given by the bank to recover the funds on deposit at the time of the failure of the bank. At the trial in the district court it was adjudged that the county had no right to the collateral notes which *737had been turned over to the treasurer, and the treasurer was ordered to turn the notes over to the-clerk of the court, who in turn was ordered to deliver the same over to the receiver of the bank. Judgment was rendered upon the bond against the bank and the-sureties on that obligation, and certain real estate belonging to C. W. Cowles was levied upon under execution issued on this judgment, and sold on May 18 and 21 and June 22, 1889. The case- was appealed to this court, and the judgment of the court below, finding that the bank had no -right to pledge its bills receivable to the county treasurer, was reversed. See 79 Iowa, 707. It was held in that case that the notes so-deposited should first be applied upon the judgment,., and that the proceeds of the real estate belonging to-the bank should not be so applied as to defeat the-application of the proceeds ratably among the creditors, and that a final decree should be rendered in harmony with the opinion. As no supersedeas was filed,, the real estate which had theretofore been sold at execution sale went to deed. It was further provided in the final decree, that, if the judgment had already been-paid by either of the sureties on the bond, the proceed of the note should be applied to reimburse them or either of them. At the time this decree was entered,, the notes, or the proceeds thereof, were in the hands of the receiver under the order of the district court, for it seems he had intervened in the suit claiming this property as assets of the bank. On the ninth day of January 1890, Seth Richards, a creditor of George H. Cowles,, brought suit against him to recover the amount of his claim,sued out an attachment, and caused it to be lev ied upon the same real estate which had therefore been sold under the judgment obtained by the county tre asurer. OnMay 15,1890, he obtained judgment and an order for the sale of the attached property, and on May 20, 1890, he began another suit, aided by attachment, le vied *738upon the same lands, and garnished the receiver and the clerk of the court as supposed debtors of Cowles. 'On October 2, 1898, this cause was dismissed for want ■of prosecution, and no move was made to reinstate it until February 18, 1895. As no claim is made under this levy and garnishment, it need not be further considered. On November 20, 1889, Findley, receiver, brought suit against the Lucas Live-Stock Company, George H. Cowles and C. W. Cowles, and recovered judgment against them for more than thirteen thousand dollars. This judgment was afterwards affirmed by this court. See 93 Iowa, 789. Thereafter, and on May 19, 1890, the receiver caused a writ of attachment to issue in said suit, which was levied upon the real estate theretofore sold under the judgment obtained by the county treasurer, and attached by Richards,, and he also caused himself to be garnished. The suit first named in the caption is the one brought by Seth Richards May 20,1890; the second is the one brought by the receiver November 20, 1889, in which Seth Richards, on or about February 1895, and after the writ of attachment was sued out, intervened, claiming that he had a lien upon the funds ■arising from the collateral notes prior and superior to •.any right or lien of the receiver; and the third is the •one docketed in the garnishment proceedings sued •out in the case first named.. The real question in the case is, which party has the better right to the funds arising out of these collateral notes, the receiver or the intervener Richards, executor?
2
*740
3
*7414 *738The contention of appellant is, to quote the language of his counsel: “First, that in equity said W. S. Richards, treasurer, should have first resorted to said notes which had been placed in his hands to indemnify him, and the moneys collected thereon, for the satisfaction of his judgment, so as to have left the real estate to be subjected under the *739attachment of Seth Eichards to the unpaid portion of his judgment; and, second, that, as said W. S. Eich-ards, treasurer, did not do this, but exhausted the real estate upon which both he and Seth Eichards had liens, the said appellant under equitable principles, is entitled to be subrogated to the lien which said W. S. Eichards, treasurer had on said notes so deposited with him, and the amount so collected thereon, to the extent that he had been deprived of his lien on said real estate.” Subrogation is well understood to be “the substitution of another person in the place of the creditor to whose rights he succeeds in relation to the debt.” It is an equitable result purely, and depends upon facts to develop its necessity that justice may be done. We do not see any room for application of this doctrine to the case at bar. Here is a contest where two creditors are each seeking to sequester a certain fund which is in the hands of an officer of court under an order placing it in his hands. What right has Seth Eichards, through his executor, to this fund, which is higher than that of the receiver, who also holds a claim against the same debtor? If Eichards, as treasurer, ever had a lien upon the fund superior to that of the receiver, and to which the appellant might, in proper case, be substituted, this right was disposed of by decree of this court in a case where all persons interested were made parties, which discharged the lien of the county treasurer, and decreed that the receiver should pay the amount of the fund to C. W. Cowles, whose land had been taken to pay the judgment. There was nothing more than a judgment obligation to pay this sum to Cowles, and no one had a lien upon it after this order was made, unless it be be Cowles. But, as. he is not attempting to enforce such a claim, the case is as if the receiver owed Cowles that amount of money. So treated, the receiver had the right to set off as against it the *740amount of the indebtedness owed by Cowles. But, whether he had this right or not, Richards has no claim to the fund in virtue of his attachment of the real estate. Surely no authorities are needed to establish these propositions. It may be that in an action between Richards, treasurer, and Seth Richards,, as creditor of Cowles, Richards, the creditor, would be entitled to the fund by reason of the right of subrogation, or, moi’e properly speaking, under the doctrine of marshaling assets. But this, as we have seen,. is a contest between two creditors to a fund upon which neither has a lien, and we know of no principle of which Richards, the creditor, may avail himself to work out a priority through Richards as treasurer. Referring to the doctrine of marshaling assets, it is well understood that where one creditor has a lien upon two funds, and a second creditor has a lien on only one of said two funds, the first creditor will, in a proper case, be compelled to first resort to that fund on which the second creditor has no lien. Massie v. Wilson, 16 Iowa, 392; Miller v. Clarke, 37 Iowa, 325. The difficulty in applying the rule to this-case lies in the fact that Findley, the receiver, the plaintiff in the case which is now being considered, has no lien upon two funds. He has no lien upon any fund, unless it be from the fact that he holds the proceeds of the collateral notes in his possession. He never had any claim upon the lands. Moreover, he does not stand in the shoes of the county treasurer. He holds the funds because turned over to him under order of court, and his right is official and personal, and not derivative. He holds, as we have already said, as a debtor of Cowles, and at the same time has a judgment in his favor as receiver for more than the amount of Cowles’ claim. It is probable that Cowles, having paid the judgment in favor of the county through the sale of his real *741estate, was subrogated to the rights of the county treasurer in these collateral notes, but that fact would not give Seth Richards, or his executor, any special claim upon or to the fund. As between the parties to this litigation, neither had a lien upon the fund, and their equities, if there be any, are equal. The receiver’s garnishment is first in point of time, however. “Where the equities are equal, the law will prevail,” is an old maxim, which may well be applied to this case. Again, this equity of marshaling assets is not one which fastens itself upon the situation at the time the successive securities are taken, but, on the contrary, is one to be determined at the time the marshaling is invoked. It can only become a fixed right by taking proper steps to have it enforced, and until this is done it is subject to displacement and •defeat by subsequently acquired liens upon the funds. This inchoate right or equity is not a lien, and is, therefore subject to defeat at any time before it is attempted to be enforced. Consequently it has often been said that marshaling will not be permitted to the prejudice of third persons. Had Seth Richards intervened in the action brought by the county treasurer, and insisted upon the marshaling of the assets, it may be that his prayer should have been granted. This he did not do. His intervention is in a case brought by another creditor of Cowles, who, by a prior garnishment, acquired a higher and better right to the fund than he has; and the facts do not present a case for the application of the equitable doctrine of marshaling. As sustaining our conclusions, see Green v. Ramage, 18 Ohio, 428; Leib v. Stribling, 51 Md. 285; Gilliam v. McCormack, 1 Pickle, 597 (Tenn. Sup.) 4 S. W. Rep., 521. The trial court correctly dismissed the petition of intervention and discharged the garnishee, Findley,, at the suit of Richards against the executor of Cowles, deceased. Affirmed.