How do i use mysql db to for autocomplete?

How do i use mysql db to for autocomplete?

I have tried several scripts but nothing will work can anyone post a sample script to query mysql and then output for autocomplete?


I would be greatly appreciative!!!