我正在try 运行一个查询,以使用更新用户密码.
alter user dell-sys with password 'Pass@133';
但是因为-
,它给了我这样的错误,
ERROR: syntax error at or near "-"
LINE 1: alter user dell-sys with password 'Pass@133';
^
有人能给它遮光吗?
我正在try 运行一个查询,以使用更新用户密码.
alter user dell-sys with password 'Pass@133';
但是因为-
,它给了我这样的错误,
ERROR: syntax error at or near "-"
LINE 1: alter user dell-sys with password 'Pass@133';
^
有人能给它遮光吗?
我已经在我的系统中复制了这个问题,
postgres=# alter user my-sys with password 'pass11';
ERROR: syntax error at or near "-"
LINE 1: alter user my-sys with password 'pass11';
^
问题是,
psql请求输入,您再次给出了alter查询,这就是为什么它在alter中给出错误
postgres-# alter user "my-sys" with password 'pass11';
ERROR: syntax error at or near "alter"
LINE 2: alter user "my-sys" with password 'pass11';
^
解决方法和错误一样简单,
postgres=# alter user "my-sys" with password 'pass11';
ALTER ROLE