471,306 Members | 848 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,306 software developers and data experts.

tsearch2 column update produces "word too long" error

Hello!

I'm currently testing deployment of tsearch2 on our forum table. The
table is huge in itself - some 2GB of data without the indexes. I have
got PostgreSQL 7.4RC2 running on a test machine, installed tsearch2 to
my database, added the new column to the table and tried to update it in
the recommended fashion:

UPDATE ct_com_board_message
SET ftindex=to_tsvector('default',coalesce(user_login, '')
||' '|| coalesce(title,'') ||' '|| coalesce(text,''));

It does run for a while but at some point I get "ERROR: word is too
long"; I guess that this is caused by some idiot user(s) writing some
Joycean nonsense (but most probably without the literary value) or
drivelling about their holidays in
Llanfairpwllgwyngyllgogerychwyrndrobwllllantysilio gogogoch (Wales). Now
what could I do in order to intercept this error?

Kind regards

Markus

---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org

Nov 12 '05 #1
1 1454
On Fri, 21 Nov 2003, Markus Wollny wrote:
Hello!

I'm currently testing deployment of tsearch2 on our forum table. The
table is huge in itself - some 2GB of data without the indexes. I have
got PostgreSQL 7.4RC2 running on a test machine, installed tsearch2 to
my database, added the new column to the table and tried to update it in
the recommended fashion:

UPDATE ct_com_board_message
SET ftindex=to_tsvector('default',coalesce(user_login, '')
||' '|| coalesce(title,'') ||' '|| coalesce(text,''));

It does run for a while but at some point I get "ERROR: word is too
long"; I guess that this is caused by some idiot user(s) writing some
Joycean nonsense (but most probably without the literary value) or
drivelling about their holidays in
Llanfairpwllgwyngyllgogerychwyrndrobwllllantysilio gogogoch (Wales). Now
what could I do in order to intercept this error?
Word length is limited by 2K. What's exactly the word tsearch2 complained on ?
'Llanfairpwllgwyngyllgogerychwyrndrobwllllantysili ogogogoch' is fine :)

btw, don't forget to configure properly dictionaries, so you don't have
a lot of unique words.

Kind regards

Markus

---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org


Regards,
Oleg
__________________________________________________ ___________
Oleg Bartunov, sci.researcher, hostmaster of AstroNet,
Sternberg Astronomical Institute, Moscow University (Russia)
Internet: ol**@sai.msu.su, 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 ma*******@postgresql.org

Nov 12 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Jessard | last post: by
2 posts views Thread by Michelle | last post: by
9 posts views Thread by Rajat Katyal | last post: by
reply views Thread by Bob Arn | last post: by
6 posts views Thread by bananaguyc | last post: by
3 posts views Thread by =?Utf-8?B?UGFvbG8=?= | last post: by
reply views Thread by rosydwin | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.