On Fri, 15 Oct 2004, Net Virtual Mailing Lists wrote:

Hello,

I have a table that uses tsearch2 and, of course, and index and trigger
to keep everything updated.....  Something like:

CREATE TABLE sometable (
   id           SERIAL,
   someinteger  INTEGER
   sometext     TEXT,
   sometext2    TEXT,
   sometext3    TEXT,
   sometext_fti TSVECTOR
);

There are two issues:

#1. I need a way to be able to do a full-text search any combination of
sometext, sometext2, and sometext3... So far the only way I've been able


.. is there some way to get the best of both worlds here or am I trying to jam a square peg into a round hole?...

Hmm, probably :) There is a hint on http://www.sai.msu.su/~megera/oddmuse/index.cgi/Tsearch_V2_Notes under section "Restricted search".



#2. When doing an update on the above table, such as: "UPDATE sometable SET someinteger=0", it ends up firing off the triggers which of course takes a long time to update... Is there someway to make the trigger only fire if a the field it is tied to is updated?.... This is not a


no idea, sorry

Thanks as always!


- Greg



---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend


Regards, Oleg _____________________________________________________________ Oleg Bartunov, sci.researcher, hostmaster of AstroNet, Sternberg Astronomical Institute, Moscow University (Russia) Internet: [EMAIL PROTECTED], http://www.sai.msu.su/~megera/ phone: +007(095)939-16-83, +007(095)939-23-83

---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

Reply via email to