-Original Message-
From: Daevid Vincent [mailto:[EMAIL PROTECTED]
Sent: Friday, May 04, 2007 1:22 AM
To: mysql@lists.mysql.com
Subject: How do I find products when a user types freeform
strings like 'Sony 20 TV' or '20 Sony TV'?
I'm having trouble figuring out the logic/query I
On 4 May 2007 at 1:21, Daevid Vincent wrote:
I'm having trouble figuring out the logic/query I want.
I know that all those ORs are not right.
[snip]
WHERE products.enabled = 1
AND(
(products.model LIKE 'sony%' OR products.model LIKE '20%' OR
products.model LIKE 'tv%')
-Original Message-
From: Iain Alexander [mailto:[EMAIL PROTECTED]
Sent: Wednesday, May 09, 2007 3:11 PM
To: mysql@lists.mysql.com
Subject: Re: How do I find products when a user types
freeform strings like 'Sony 20 TV' or '20 Sony TV'?
On 4 May 2007 at 1:21, Daevid Vincent wrote
Daevid,
It occurs to me that what you were explaining was multi-column keyword
search which MySQL does not support as of now. You may even face scenarios
where you need multi-table and multi-column keyword search (even in your
example, this may come up). In brief, you have a set of keywords and
I'm having trouble figuring out the logic/query I want.
I know that all those ORs are not right.
I'm doing this in PHP and mySQL (of course),
so if it can't be done with a single query, I can split it up.
Here's the challenge, given a text field search box, someone enters:
Sony 20 TV
On Fri, May 4, 2007 10:21, Daevid Vincent wrote:
I'm having trouble figuring out the logic/query I want.
I know that all those ORs are not right.
I'm doing this in PHP and mySQL (of course),
so if it can't be done with a single query, I can split it up.
Here's the challenge, given a text
Hi Daevid,
Daevid Vincent wrote:
I'm having trouble figuring out the logic/query I want.
I know that all those ORs are not right.
I'm doing this in PHP and mySQL (of course),
so if it can't be done with a single query, I can split it up.
Here's the challenge, given a text field search box,
-Original Message-
From: Baron Schwartz [mailto:[EMAIL PROTECTED]
Daevid Vincent wrote:
I'm having trouble figuring out the logic/query I want.
I know that all those ORs are not right.
I'm doing this in PHP and mySQL (of course),
so if it can't be done with a single query, I
Hi Daevid,
Daevid Vincent wrote:
-Original Message-
From: Baron Schwartz [mailto:[EMAIL PROTECTED]
Daevid Vincent wrote:
I'm having trouble figuring out the logic/query I want.
I know that all those ORs are not right.
I'm doing this in PHP and mySQL (of course),
so if it can't be