abstracted the search list to work with codes