I'm trying to create a database link on one database, so I can view tables on another database.
The password to the other database is Bl$nk-d8prd, it doesn't seem to like the "-" in the password Bl$nk-d8prd because when I don't include the "-" and use Bl$nkd8prd the database link is created. Is there a restriction on characters you can use in the password when creating a database link?
Obviously the new database link does not work as the password is wrong.
How do I overcome this problem with the "-" in the password Bl$nk-d8prd without changing the password.
CREATE DATABASE LINK D8PRD
CONNECT TO PRBL IDENTIFIED BY Bl$nk-d8prd
USING 'D8PRD';
thanks in advance.
Originally Oracle SQL parser treated passwords the same way as identifiers. (leading with a char, 30 chars max length). So dash was not allowed and password must not start with a digit.
Now those constraints are more relaxed, but you must use double quotes around such "identifiers".
You still might face problems it rare cases when using such chars in passwords. The rule of thumb is to avoid them. For example your password might start with a digit but Oracle Cloud Control does not support that.