I have a char field called Ads in my table... the field contains the sort of Ads that are placed on pages. The field will either have one or a combination of the following:
I know ow you handle a SELECT statement if searching for records with None in the Ads field, but if one record had the following in the Ads field: "Frame Delay" meaning that either a Frame of Delay ad is used, how would I be able to search for "Frame" and still be able to pull records that contained "Frame Delay" from the table? What, if possible, would the SQL statement look like?
I think I just figured it out :)
I added % to the search term...
if you searched for "Frame" I just made it "Frame %" and it listed records with "Frame Delay"
Yes. A % sign is the wildcard figure for SQL.
If you had a DB of names and wanted to return all of them that started with A you'd search for A%. Or all of the ones that ended with A you'd search for %A. Or if you just wanted all names you'd search for %.
Steve, from the description of what your field is supposed to do, it sounds to me like you should be using a SET column, not a CHAR column.
Ok, I'm just learning MySQL and PHP... what is a SET? Can you point me to any good sites that list info like this (besides the docs on MySQL and PHP sites)