record number of previous nearby points and distance criteria in db