Oracle 更改密码,其中旧密码包含@-符号

Oracle changing password, where old password contain @-signs

假设我有一个密码名称 T@mp

我想改成你好

但是如果我对我的用户使用以下查询,它将无法编译,因为我的旧密码包含@-signs

alter user MYUSER identified by Hello replace T@mp

我正在使用 TOAD

我正在将密码更改为普通字符,因为 @-signs 也会在 SQL 加载器

中造成问题
sqlldr myuser/T@mp@prodcms control=loading.ctl

如@Wernfried Domscheit 所示,您必须将旧密码用双引号引起来,如下所示。

SQL> alter user sales_hr identified by password replace p@assword;
alter user sales_hr identified by password replace p@assword
                                                        *
ERROR at line 1:
ORA-00922: missing or invalid option


SQL> alter user sales_hr identified by password replace "p@ssword";

User altered.