If you're using MySQL as your database system, you may want to look into
full-text search as well as the LIKE keyword.

http://www.mysql.com/doc/en/Fulltext_Search.html
http://www.mysql.com/doc/en/String_comparison_functions.html

HTH,
-Dan


"Mike Tuller" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> I am wanting to add a simple search field where you enter your search
> and it searches the whole database, not just one column. It would be
> easy for one column ( SELECT * FROM clients WHERE first_name =
> '$first_name';) but how do I search the whole table? Do I have to
> search each column one by one or is there an easier, more efficient way
> of doing this?
>
> Thanks,
>
> Mike
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to