mirror of
https://github.com/postgres/postgres.git
synced 2025-06-01 14:21:49 +03:00
Improve error message in WAL sender
The previous error message when attempting to run a general SQL command in a physical replication WAL sender was a bit sloppy. Reported-by: Fujii Masao <masao.fujii@gmail.com>
This commit is contained in:
parent
b1705f35f8
commit
2b0ded5060
@ -1545,7 +1545,7 @@ exec_replication_command(const char *cmd_string)
|
|||||||
case T_SQLCmd:
|
case T_SQLCmd:
|
||||||
if (MyDatabaseId == InvalidOid)
|
if (MyDatabaseId == InvalidOid)
|
||||||
ereport(ERROR,
|
ereport(ERROR,
|
||||||
(errmsg("not connected to database")));
|
(errmsg("cannot execute SQL commands in WAL sender for physical replication")));
|
||||||
|
|
||||||
/* Tell the caller that this wasn't a WalSender command. */
|
/* Tell the caller that this wasn't a WalSender command. */
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user