Search Postgresql Archives

Re: tsearch2 problems / limitations

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Feb 22, 2005 at 01:29:45PM +0000, James Croft wrote:

> One of the tables holds reasonable amounts of text, some fields hold up 
> to 2Mb. When I try and run
> 
> UPDATE table SET idxfti=to_tsvector('default', field);
> 
> it runs for a while then aborts with the following message
> 
> ERROR:  value is too big

README.tsearch2 says that the maximum size of a tsvector is 2^20
bytes (1M).  You can see that limit enforced in the makevalue()
function in tsvector.c (similarly in pushquery() in query.c):

    if (cur - str > MAXSTRPOS)
        ereport(ERROR,
                (errcode(ERRCODE_SYNTAX_ERROR),
                 errmsg("value is too big")));

MAXSTRPOS is defined in tsvector.h:

  #define MAXSTRPOS ( 1<<20 )

Maybe Oleg will reply and say whether it's safe to change that
or not.

-- 
Michael Fuhr
http://www.fuhr.org/~mfuhr/

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux