§ 246. Notices of filing liens and certificate of discharge. Notice of surety bond liens in favor of the people of the state of New York as provided in section two hundred forty-six of this article and certificates discharging such liens may be filed in the office of the recording officer of the county in which real property subject to any such lien is situated, and if such property be situated in two or more counties, such notice may be filed in the office of the recording officer of each of such counties. Until the filing of such notice, such lien shall not be valid as against any mortgagee, purchaser or judgment creditor having or claiming any right, title or interest in or to or lien against such property, or any part thereof.