Forum OpenACS Q&A: Re: DB Smarties Question :) - Inverted Index / Concordance of Unique Words in a Field

PG 7.3 supports functions that return a rowset, so you can define a PL/PGSQL function that scans the input text and returns SETOF varchar and then join against that...

check section 19.6.1 of the PG 7.3 manual (Procedural Languages / PLPGSQL / Control Structures)