Re: conditions in select * from

From: Date: Thu, 01 Jan 1970 00:00:00 +0000
Subject: Re: conditions in select * from
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-468@lists.php.net to get a copy of this message
On Sun, 18 Jun 2000, sarahana wrote: > Hi, > I was just wondering... > > Let's say a user chooses a word. And I want to select those entries in a > database table for which the word exists as a PART of the data of the > field name... i.e. the word may not be the data in the name field, but > it may be a PART of the string. > > How can I do that? Depends on what database you are running. MySQL does it like this: <URL:http://www.mysql.com/Manual_chapter/manual_Reference.html#String_comparison_functions> The LIKE operator is the same in most SQL implementations. -- Morten Dreier Institutt for Datateknikk og Informasjonsvitenskap http://www.ifi.ntnu.no/~mdreier/

« previous php.db (#468) next »