[SQL] simple web search

2007-02-23 Thread Louis-David Mitterrand
Hello, I'm considering implementing a search box on my review web site http://lesculturelles.net and am looking for a simple way to match entered words against several columns on related tables: show.show_name, story.title, person.firtname, person.lastname, etc. What is the most elegant way

Re: [SQL] simple web search

2007-02-23 Thread chester c young
I'm considering implementing a search box on my review web site http://lesculturelles.net and am looking for a simple way to match entered words against several columns on related tables: show.show_name, story.title, person.firtname, person.lastname, etc. one solution would be a view:

Re: [SQL] simple web search

2007-02-23 Thread Louis-David Mitterrand
On Fri, Feb 23, 2007 at 10:01:22AM -0800, chester c young wrote: I'm considering implementing a search box on my review web site http://lesculturelles.net and am looking for a simple way to match entered words against several columns on related tables: show.show_name, story.title,

Re: [SQL] simple web search

2007-02-23 Thread chester c young
create view search_v as select 'show'::name as tab_nm, show_id as tab_pk, 'Show Name' as description, show_name as search from show union select 'story'::name, story_id, 'Story Title', title from story union ... What is that ::name cast for?

Re: [SQL] simple web search

2007-02-23 Thread Joe
Hello Louis-David, On Fri, 2007-02-23 at 17:27 +0100, Louis-David Mitterrand wrote: I'm considering implementing a search box on my review web site http://lesculturelles.net and am looking for a simple way to match entered words against several columns on related tables: show.show_name,

Re: [SQL] simple web search

2007-02-23 Thread Oleg Bartunov
I think contrib/tsearch2 http://www.sai.msu.su/~megera/postgres/gist/tsearch/V2/ is what you need. Oleg On Fri, 23 Feb 2007, chester c young wrote: I'm considering implementing a search box on my review web site http://lesculturelles.net and am looking for a simple way to match entered words

Re: [SQL] simple web search

2007-02-23 Thread Louis-David Mitterrand
On Fri, Feb 23, 2007 at 01:31:14PM -0500, Joe wrote: Hello Louis-David, On Fri, 2007-02-23 at 17:27 +0100, Louis-David Mitterrand wrote: I'm considering implementing a search box on my review web site http://lesculturelles.net and am looking for a simple way to match entered words

Re: [SQL] simple web search

2007-02-23 Thread Oleg Bartunov
On Fri, 23 Feb 2007, Louis-David Mitterrand wrote: On Fri, Feb 23, 2007 at 01:31:14PM -0500, Joe wrote: Hello Louis-David, On Fri, 2007-02-23 at 17:27 +0100, Louis-David Mitterrand wrote: I'm considering implementing a search box on my review web site http://lesculturelles.net and am looking