three stage search