Re: [PHP] Keyword Search

2004-04-06 Thread John W. Holmes
From: "Robb Kerr" <[EMAIL PROTECTED]> > I've inherited a database so must live with a less than elegant structure. > The table contains one "keyword" field into which the author has entered > things like... > > Record 1 = Apples > Record 2 = Apples, Bananas > Record 3 = Apples, Figs > Record 4 = B

RE: [PHP] Keyword Search

2004-04-06 Thread Jay Blanchard
[snip] Thanx for the advice. I'll give it a try. BTW, I know that some of my questions belong on a SQL list. Can you recommend any? I haven't found any as active or helpful as this PHP one. [/snip] Some of them depend on the database in question. For MySql [EMAIL PROTECTED] is a good one. Many not

Re: [PHP] Keyword Search

2004-04-06 Thread Robb Kerr
On Tue, 6 Apr 2004 11:25:09 -0500, Jay Blanchard wrote: > [snip] > I've inherited a database so must live with a less than elegant > structure. > The table contains one "keyword" field into which the author has entered > things like... > > Record 1 = Apples > Record 2 = Apples, Bananas > Record 3

Re: [PHP] Keyword Search

2004-04-06 Thread Richard Davey
Hello Robb, Tuesday, April 6, 2004, 5:24:55 PM, you wrote: RK> I need to do a search on this field to return all of the records containing RK> "Figs". What's the search syntax? RK> I've tried... RK> SELECT * from dbname.tablename MATCH (dbname.fieldname) AGAINST 'Figs' RK> It doesnt' work. Does

RE: [PHP] Keyword Search

2004-04-06 Thread Jay Blanchard
[snip] I've inherited a database so must live with a less than elegant structure. The table contains one "keyword" field into which the author has entered things like... Record 1 = Apples Record 2 = Apples, Bananas Record 3 = Apples, Figs Record 4 = Bananas, Figs, Dates I need to do a search on t

[PHP] Keyword Search

2004-04-06 Thread Robb Kerr
I've inherited a database so must live with a less than elegant structure. The table contains one "keyword" field into which the author has entered things like... Record 1 = Apples Record 2 = Apples, Bananas Record 3 = Apples, Figs Record 4 = Bananas, Figs, Dates I need to do a search on this fie

Re: [PHP] keyword search syntax

2003-10-28 Thread Robb Kerr
On Tue, 28 Oct 2003 19:37:10 +0600, Raditha Dissanayake wrote: > If you put up a full text index on it you can do searches that smell > like a primitive search engine. > > best regards Thanx. The LIKE operator wouldn't work. But, your tip on creating a FULLTEXT index and executing a MATCH... AG

Re: [PHP] keyword search syntax

2003-10-28 Thread Raditha Dissanayake
If you put up a full text index on it you can do searches that smell like a primitive search engine. best regards Robb Kerr wrote: On Tue, 28 Oct 2003 02:09:06 +, David Otton wrote: Personally, I'd normalize that into a keyword table, a record table and a joining table. However, the SQL

Re: [PHP] keyword search syntax

2003-10-27 Thread Robb Kerr
On Tue, 28 Oct 2003 02:09:06 +, David Otton wrote: > > Personally, I'd normalize that into a keyword table, a record table and a > joining table. > > However, the SQL keyword you're looking for is LIKE > > WHERE field LIKE '%$variable%' I agree. I'd structure the data quite differently. Bu

Re: [PHP] keyword search syntax

2003-10-27 Thread David Otton
On Mon, 27 Oct 2003 20:00:24 -0600, you wrote: >I've got a field in my database that contains keywords about the particular >record. I've got a form with a text entry field for visitors to enter >keywords for which they would like to find records whose keyword field >contains the words they entere

[PHP] keyword search syntax

2003-10-27 Thread Robb Kerr
I've got a field in my database that contains keywords about the particular record. I've got a form with a text entry field for visitors to enter keywords for which they would like to find records whose keyword field contains the words they entered. The submission form assigns the keywords entered

Re: [PHP] keyword search help

2002-02-07 Thread Jeff Sheltren
Not really a php question, is it? But what I would do is have two tables, a cdrom table and a keyword table. Each cd in the cd table would have a cd_id, and then the keyword table could have two attributes, cd_id (foriegn key from cdrom table) and keyword. Make the primary key for the keywor

[PHP] keyword search help

2002-02-07 Thread Arun K . V
hello sir, we are creating a cdrom database in postgresql wherein we have cd rom titlename,author,year etc and keywords as fields. we will store a set of keywords for each record. i want to know how to enter those keywords in to database (whether to have comma between keywords or pla