| From: | Dharin Shah <dharinshah95(at)gmail(dot)com> |
|---|---|
| To: | pgsql-hackers(at)lists(dot)postgresql(dot)org |
| Subject: | [PATCH][DOC][MINOR] Fix incorrect lexeme limit in textsearch docs |
| Date: | 2025-12-27 21:09:14 |
| Message-ID: | CAOj6k6d0YO6AO-bhxkfUXPxUi-+YX9-doh2h5D5z0Bm8D2w=OA@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Hello,
A minor doc patch for this page
https://www.postgresql.org/docs/current/textsearch-limitations.html
and this line
*- The number of lexemes must be less than 2^64*
Docs wrongly claim "lexemes must be < 2^64" but the actual constraint is
1 MB total storage (MAXSTRPOS), and no 2^64 check exists in the code.
From src/include/tsearch/ts_type.h:
> #define MAXSTRPOS ( (1<<20) - 1) // 1,048,575 bytes
>
> typedef struct {
> int32 size; // number of lexemes
> ...
> } TSVectorData;
The attached patch:
- Removes the incorrect 2^64 claim
- Clarifies this means "distinct lexemes in a single tsvector value"
Thanks,
Dharin
| Attachment | Content-Type | Size |
|---|---|---|
| 0001-docs-Fix-incorrect-tsvector-lexeme-limit-in-textsear.patch | application/octet-stream | 1.3 KB |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Daniel Gustafsson | 2025-12-27 21:14:49 | Re: Fix typos: 'Bejing' to 'Beijing' in partition regress/docs |
| Previous Message | Daniel Gustafsson | 2025-12-27 20:37:41 | Re: Missing oauth_validator_libraries in variable_is_guc_list_quote() |