At any time after any taxes or special assessments or any installment thereof, heretofore or hereafter levied and assessed upon any real property within this state, have been delinquent for more than twelve months, and remain due and unpaid, the county treasurer, if the said property produces rents, may petition, and, by direction of the board of county commissioners, shall petition, the district court, in the name of the county, for an order directed to the tenant or subtenant, if any, and to the owner of said property, directing that said rents be paid to the county treasurer.
N.D.C.C. § 57-21-01