Datatable Search (via a Searchbar)

cant get it to work yet everyime i press a key it adds another of the same even when i erase the letters and cant get it to erase the extras and also to give more possibles without repeating and adding wore children and id like ir to give possibles with simular letters without adding alot of children ive tried it several ways


This is what i have so far but it has alot of bugsbut its the only way yet that i have been able to get a output = to what im typeing