Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Greenplum
Gpdb
提交
072457b3
G
Gpdb
项目概览
Greenplum
/
Gpdb
通知
7
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
Gpdb
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
072457b3
编写于
8月 09, 2013
作者:
P
Peter Eisentraut
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Message punctuation and pluralization fixes
上级
9d775d88
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
32 addition
and
24 deletion
+32
-24
src/backend/access/transam/multixact.c
src/backend/access/transam/multixact.c
+12
-4
src/backend/access/transam/xlog.c
src/backend/access/transam/xlog.c
+1
-1
src/backend/utils/adt/json.c
src/backend/utils/adt/json.c
+7
-7
src/backend/utils/adt/jsonfuncs.c
src/backend/utils/adt/jsonfuncs.c
+2
-2
src/test/regress/expected/json.out
src/test/regress/expected/json.out
+4
-4
src/test/regress/expected/json_1.out
src/test/regress/expected/json_1.out
+6
-6
未找到文件。
src/backend/access/transam/multixact.c
浏览文件 @
072457b3
...
...
@@ -940,14 +940,18 @@ GetNewMultiXactId(int nmembers, MultiXactOffset *offset)
/* complain even if that DB has disappeared */
if
(
oldest_datname
)
ereport
(
WARNING
,
(
errmsg
(
"database
\"
%s
\"
must be vacuumed before %u more MultiXactIds are used"
,
(
errmsg_plural
(
"database
\"
%s
\"
must be vacuumed before %u more MultiXactId is used"
,
"database
\"
%s
\"
must be vacuumed before %u more MultiXactIds are used"
,
multiWrapLimit
-
result
,
oldest_datname
,
multiWrapLimit
-
result
),
errhint
(
"Execute a database-wide VACUUM in that database.
\n
"
"You might also need to commit or roll back old prepared transactions."
)));
else
ereport
(
WARNING
,
(
errmsg
(
"database with OID %u must be vacuumed before %u more MultiXactIds are used"
,
(
errmsg_plural
(
"database with OID %u must be vacuumed before %u more MultiXactId is used"
,
"database with OID %u must be vacuumed before %u more MultiXactIds are used"
,
multiWrapLimit
-
result
,
oldest_datoid
,
multiWrapLimit
-
result
),
errhint
(
"Execute a database-wide VACUUM in that database.
\n
"
...
...
@@ -1982,14 +1986,18 @@ SetMultiXactIdLimit(MultiXactId oldest_datminmxid, Oid oldest_datoid)
if
(
oldest_datname
)
ereport
(
WARNING
,
(
errmsg
(
"database
\"
%s
\"
must be vacuumed before %u more MultiXactIds are used"
,
(
errmsg_plural
(
"database
\"
%s
\"
must be vacuumed before %u more MultiXactId is used"
,
"database
\"
%s
\"
must be vacuumed before %u more MultiXactIds are used"
,
multiWrapLimit
-
curMulti
,
oldest_datname
,
multiWrapLimit
-
curMulti
),
errhint
(
"To avoid a database shutdown, execute a database-wide VACUUM in that database.
\n
"
"You might also need to commit or roll back old prepared transactions."
)));
else
ereport
(
WARNING
,
(
errmsg
(
"database with OID %u must be vacuumed before %u more MultiXactIds are used"
,
(
errmsg_plural
(
"database with OID %u must be vacuumed before %u more MultiXactId is used"
,
"database with OID %u must be vacuumed before %u more MultiXactIds are used"
,
multiWrapLimit
-
curMulti
,
oldest_datoid
,
multiWrapLimit
-
curMulti
),
errhint
(
"To avoid a database shutdown, execute a database-wide VACUUM in that database.
\n
"
...
...
src/backend/access/transam/xlog.c
浏览文件 @
072457b3
...
...
@@ -6138,7 +6138,7 @@ StartupXLOG(void)
ereport
(
ERROR
,
(
errcode
(
ERRCODE_OUT_OF_MEMORY
),
errmsg
(
"out of memory"
),
errdetail
(
"Failed while allocating an XLog reading processor"
)));
errdetail
(
"Failed while allocating an XLog reading processor
.
"
)));
xlogreader
->
system_identifier
=
ControlFile
->
system_identifier
;
if
(
read_backup_label
(
&
checkPointLoc
,
&
backupEndRequired
,
...
...
src/backend/utils/adt/json.c
浏览文件 @
072457b3
...
...
@@ -728,7 +728,7 @@ json_lex_string(JsonLexContext *lex)
ereport
(
ERROR
,
(
errcode
(
ERRCODE_INVALID_TEXT_REPRESENTATION
),
errmsg
(
"invalid input syntax for type json"
),
errdetail
(
"
high order surrogate must not follow a high order
surrogate."
),
errdetail
(
"
Unicode high surrogate must not follow a high
surrogate."
),
report_json_context
(
lex
)));
hi_surrogate
=
(
ch
&
0x3ff
)
<<
10
;
continue
;
...
...
@@ -739,7 +739,7 @@ json_lex_string(JsonLexContext *lex)
ereport
(
ERROR
,
(
errcode
(
ERRCODE_INVALID_TEXT_REPRESENTATION
),
errmsg
(
"invalid input syntax for type json"
),
errdetail
(
"
low order surrogate must follow a high order
surrogate."
),
errdetail
(
"
Unicode low surrogate must follow a high
surrogate."
),
report_json_context
(
lex
)));
ch
=
0x10000
+
hi_surrogate
+
(
ch
&
0x3ff
);
hi_surrogate
=
-
1
;
...
...
@@ -749,7 +749,7 @@ json_lex_string(JsonLexContext *lex)
ereport
(
ERROR
,
(
errcode
(
ERRCODE_INVALID_TEXT_REPRESENTATION
),
errmsg
(
"invalid input syntax for type json"
),
errdetail
(
"
low order surrogate must follow a high order
surrogate."
),
errdetail
(
"
Unicode low surrogate must follow a high
surrogate."
),
report_json_context
(
lex
)));
/*
...
...
@@ -783,7 +783,7 @@ json_lex_string(JsonLexContext *lex)
ereport
(
ERROR
,
(
errcode
(
ERRCODE_INVALID_TEXT_REPRESENTATION
),
errmsg
(
"invalid input syntax for type json"
),
errdetail
(
"Unicode escape
for code points higher than U+007F not permitted in non-UTF8 encoding
"
),
errdetail
(
"Unicode escape
values cannot be used for code point values above 007F when the server encoding is not UTF8.
"
),
report_json_context
(
lex
)));
}
...
...
@@ -795,7 +795,7 @@ json_lex_string(JsonLexContext *lex)
ereport
(
ERROR
,
(
errcode
(
ERRCODE_INVALID_TEXT_REPRESENTATION
),
errmsg
(
"invalid input syntax for type json"
),
errdetail
(
"
low order surrogate must follow a high order
surrogate."
),
errdetail
(
"
Unicode low surrogate must follow a high
surrogate."
),
report_json_context
(
lex
)));
switch
(
*
s
)
...
...
@@ -856,7 +856,7 @@ json_lex_string(JsonLexContext *lex)
ereport
(
ERROR
,
(
errcode
(
ERRCODE_INVALID_TEXT_REPRESENTATION
),
errmsg
(
"invalid input syntax for type json"
),
errdetail
(
"
low order surrogate must follow a high order
surrogate."
),
errdetail
(
"
Unicode low surrogate must follow a high
surrogate."
),
report_json_context
(
lex
)));
appendStringInfoChar
(
lex
->
strval
,
*
s
);
...
...
@@ -868,7 +868,7 @@ json_lex_string(JsonLexContext *lex)
ereport
(
ERROR
,
(
errcode
(
ERRCODE_INVALID_TEXT_REPRESENTATION
),
errmsg
(
"invalid input syntax for type json"
),
errdetail
(
"
low order surrogate must follow a high order
surrogate."
),
errdetail
(
"
Unicode low surrogate must follow a high
surrogate."
),
report_json_context
(
lex
)));
/* Hooray, we found the end of the string! */
...
...
src/backend/utils/adt/jsonfuncs.c
浏览文件 @
072457b3
...
...
@@ -1239,7 +1239,7 @@ json_populate_record(PG_FUNCTION_ARGS)
if
(
!
type_is_rowtype
(
argtype
))
ereport
(
ERROR
,
(
errcode
(
ERRCODE_DATATYPE_MISMATCH
),
errmsg
(
"first argument
must be a row
type"
)));
errmsg
(
"first argument
of json_populate_record must be a row
type"
)));
if
(
PG_ARGISNULL
(
0
))
{
...
...
@@ -1581,7 +1581,7 @@ json_populate_recordset(PG_FUNCTION_ARGS)
if
(
!
type_is_rowtype
(
argtype
))
ereport
(
ERROR
,
(
errcode
(
ERRCODE_DATATYPE_MISMATCH
),
errmsg
(
"first argument
must be a row
type"
)));
errmsg
(
"first argument
of json_populate_recordset must be a row
type"
)));
rsi
=
(
ReturnSetInfo
*
)
fcinfo
->
resultinfo
;
...
...
src/test/regress/expected/json.out
浏览文件 @
072457b3
...
...
@@ -929,19 +929,19 @@ select json '{ "a": "\ud83d\ude04\ud83d\udc36" }' -> 'a' as correct_in_utf8;
select json '{ "a": "\ud83d\ud83d" }' -> 'a'; -- 2 high surrogates in a row
ERROR: invalid input syntax for type json
DETAIL:
high order surrogate must not follow a high order
surrogate.
DETAIL:
Unicode high surrogate must not follow a high
surrogate.
CONTEXT: JSON data, line 1: { "a":...
select json '{ "a": "\ude04\ud83d" }' -> 'a'; -- surrogates in wrong order
ERROR: invalid input syntax for type json
DETAIL:
low order surrogate must follow a high order
surrogate.
DETAIL:
Unicode low surrogate must follow a high
surrogate.
CONTEXT: JSON data, line 1: { "a":...
select json '{ "a": "\ud83dX" }' -> 'a'; -- orphan high surrogate
ERROR: invalid input syntax for type json
DETAIL:
low order surrogate must follow a high order
surrogate.
DETAIL:
Unicode low surrogate must follow a high
surrogate.
CONTEXT: JSON data, line 1: { "a":...
select json '{ "a": "\ude04X" }' -> 'a'; -- orphan low surrogate
ERROR: invalid input syntax for type json
DETAIL:
low order surrogate must follow a high order
surrogate.
DETAIL:
Unicode low surrogate must follow a high
surrogate.
CONTEXT: JSON data, line 1: { "a":...
--handling of simple unicode escapes
select json '{ "a": "the Copyright \u00a9 sign" }' ->> 'a' as correct_in_utf8;
...
...
src/test/regress/expected/json_1.out
浏览文件 @
072457b3
...
...
@@ -923,28 +923,28 @@ ERROR: cannot call json_populate_recordset on a nested object
-- handling of unicode surrogate pairs
select json '{ "a": "\ud83d\ude04\ud83d\udc36" }' -> 'a' as correct_in_utf8;
ERROR: invalid input syntax for type json
DETAIL: Unicode escape
for code points higher than U+007F not permitted in non-UTF8 encoding
DETAIL: Unicode escape
values cannot be used for code point values above 007F when the server encoding is not UTF8.
CONTEXT: JSON data, line 1: { "a":...
select json '{ "a": "\ud83d\ud83d" }' -> 'a'; -- 2 high surrogates in a row
ERROR: invalid input syntax for type json
DETAIL:
high order surrogate must not follow a high order
surrogate.
DETAIL:
Unicode high surrogate must not follow a high
surrogate.
CONTEXT: JSON data, line 1: { "a":...
select json '{ "a": "\ude04\ud83d" }' -> 'a'; -- surrogates in wrong order
ERROR: invalid input syntax for type json
DETAIL:
low order surrogate must follow a high order
surrogate.
DETAIL:
Unicode low surrogate must follow a high
surrogate.
CONTEXT: JSON data, line 1: { "a":...
select json '{ "a": "\ud83dX" }' -> 'a'; -- orphan high surrogate
ERROR: invalid input syntax for type json
DETAIL:
low order surrogate must follow a high order
surrogate.
DETAIL:
Unicode low surrogate must follow a high
surrogate.
CONTEXT: JSON data, line 1: { "a":...
select json '{ "a": "\ude04X" }' -> 'a'; -- orphan low surrogate
ERROR: invalid input syntax for type json
DETAIL:
low order surrogate must follow a high order
surrogate.
DETAIL:
Unicode low surrogate must follow a high
surrogate.
CONTEXT: JSON data, line 1: { "a":...
--handling of simple unicode escapes
select json '{ "a": "the Copyright \u00a9 sign" }' ->> 'a' as correct_in_utf8;
ERROR: invalid input syntax for type json
DETAIL: Unicode escape
for code points higher than U+007F not permitted in non-UTF8 encoding
DETAIL: Unicode escape
values cannot be used for code point values above 007F when the server encoding is not UTF8.
CONTEXT: JSON data, line 1: { "a":...
select json '{ "a": "dollar \u0024 character" }' ->> 'a' as correct_everywhere;
correct_everywhere
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录