The % can be empty space or 'n' characthers. The LIKE command in mysql also
make the query very dynamic.
- trond

> -----Opprinnelig melding-----
> Fra: Dave Watkinson [mailto:[EMAIL PROTECTED]]
> Sendt: 18. oktober 2001 14:50
> Til: [EMAIL PROTECTED]
> Emne: RE: [PHP-DB] wildcard in mysql search with php
>
>
> select <columnlist> from <tablename> where <columnname> like
> '%searchword%'
>
>
> RTFM!!!
>
>
>
> -----Original Message-----
> From: Thomas "omega" Henning [mailto:[EMAIL PROTECTED]]
> Sent: 18 October 2001 14:58
> To: [EMAIL PROTECTED]
> Subject: [PHP-DB] wildcard in mysql search with php
>
>
> Hello all,
>
> Is there a way to use wildcards in search in a mySQL db?
> e.g. I have a dbase of over 24000 records and i can only search exact
> matches is there a way to search something like this : *admin* in mySQL?
> Or
> i have to do it by hand in PHP?
>
> Thanks
> Sir Thomas "omega" Henning
>
>
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to