My Last post was incorrect - sorry. My correct sql statement would be
rlike (^|;)Midwest(;|$).
Someone mentioned using Distinct before, which wouldn't work because
Distinct acts on a field, to my understanding, so Northwest;East would
be different than Northwest;South so it wouldn't really give
Couldn't you useSELECT DISTINCT for this?
http://www.mysql.com/doc/S/E/SELECT.html
- Original Message -
From: Joseph Koenig [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, June 27, 2001 8:54 AM
Subject: [PHP-DB] Modify Query, or sift through results?
I've got a
Hi,
you could use the FIND_IN_SET(str,strlist) function which returns a value 1
to N if the string str is in the list strlist consisting of N substrings.
Returns 0 if str is not in strlist or if strlist is the empty string.
Returns NULL if either argument is NULL.
If you want to find all the
On Wed, Jun 27, 2001 at 08:54:04AM -0500, Joseph Koenig wrote:
I've got a script that searches a db every night and sends out e-mail if
it finds something a person would be interested in, based on criteria
they gave us. The problem is that I have one field that stores regions
of the country
Ah ha..now it looks like we're on to something. I had to modify it a
bit, but it worked...for the most part. I had to make it rlike
North[;|$]. But here's the next problem...I have a region 'Midwest'
and 'Upper Midwest'. When I do this search for Midwest, I get the 'Upper
Midwest' results also.