If the interest of the owner in the building, structure or land is under attachment at the time of filing and recording the statement of the account, the attaching creditor shall be preferred to the extent of the value of the buildings and land as they were when the statement was recorded and the court shall ascertain, by a jury or otherwise as the case may require, what proportion of the proceeds of the sale shall be held subject to the attachment as derived from the value of the property when the statement was recorded.
S.C. Code § 29-5-320