fix local database search