Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit085400f

Browse files
committed
Improve error message about valid value for distance in phrase operator.
The distance in phrase operator must be an integer value between zeroand MAXENTRYPOS inclusive. But previously the error message aboutits valid value included the information about its upper limitbut not lower limit (i.e., zero). This commit improves the error messageso that it also includes the information about its lower limit.Back-patch to v9.6 where full-text phrase search was supported.Author: Kyotaro HoriguchiReviewed-by: Fujii MasaoDiscussion:https://postgr.es/m/20210819.170315.1413060634876301811.horikyota.ntt@gmail.com
1 parent71fee6c commit085400f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎src/backend/utils/adt/tsquery.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ parse_phrase_operator(TSQueryParserState pstate, int16 *distance)
196196
elseif (errno==ERANGE||l<0||l>MAXENTRYPOS)
197197
ereport(ERROR,
198198
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
199-
errmsg("distance in phrase operatorshould notbegreater than %d",
199+
errmsg("distance in phrase operatormustbean integer value between zero and %d inclusive",
200200
MAXENTRYPOS)));
201201
else
202202
{

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp