Bruce Momjian wrote:
> Tom Lane wrote:
> > Bruce Momjian <[EMAIL PROTECTED]> writes:
> > > Thanks, working on this now.  Because the stop words can be any stop
> > > word I didn't imagine it could be in the subsitution.  What stop word
> > > will it use?  Anyway, coding it now to match the left-hand-side.
> > 
> > Why would you do that?  There is not any corresponding idea of leaving
> > holes in the pattern.  AFAICS the only change needed is NOTICE->ERROR.
> 
> OK, I see now.  The right-hand side just ignores a stop word, rather
> than accepting any stop word.  Got it.
> 
> So, for the left-hand-side we have '?' as any stop word and a stop word
> as an error, and you want to make a stop word as an error on the
> right-hand-size.  No need for '?'.  Agreed.  Want me to do it?

I have applied the attached patch to change the NOTICE to ERROR.  Thanks
for spotting this.

-- 
  Bruce Momjian  <[EMAIL PROTECTED]>        http://momjian.us
  EnterpriseDB                             http://postgres.enterprisedb.com

  + If your life is a hard drive, Christ can be your backup. +
Index: src/backend/tsearch/dict_thesaurus.c
===================================================================
RCS file: /cvsroot/pgsql/src/backend/tsearch/dict_thesaurus.c,v
retrieving revision 1.8
diff -c -c -r1.8 dict_thesaurus.c
*** src/backend/tsearch/dict_thesaurus.c	15 Nov 2007 22:25:16 -0000	1.8
--- src/backend/tsearch/dict_thesaurus.c	28 Nov 2007 04:22:08 -0000
***************
*** 570,576 ****
  			}
  			else if (lexized)
  			{
! 				elog(NOTICE, "thesaurus word \"%s\" in substitution is a stop-word, ignored (rule %d)", inptr->lexeme, i + 1);
  			}
  			else
  			{
--- 570,576 ----
  			}
  			else if (lexized)
  			{
! 				elog(ERROR, "thesaurus word \"%s\" in substitution is a stop-word (rule %d)", inptr->lexeme, i + 1);
  			}
  			else
  			{
---------------------------(end of broadcast)---------------------------
TIP 6: explain analyze is your friend

Reply via email to