Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Cannot create new user in PL/SQL code if password starts with number

User_M8EXOJul 18 2012 — edited Jul 18 2012
I have to create numerous users in PL/SQL dynamically and with specific passwords. I have to use the passwords given to me. The problem is some passwords start with numbers and I get 'SQL Error: ORA-00922: missing or invalid option' errors when trying to create the users. If I remove any leading numbers the user is created with no problem. Also, if I use a GUI (TOAD or SQL Developer) I can create a user with a password starting with a number. Does anyone have a workaround?

Oracle Version: Oracle Database 11g 11.2.0.1.0

Example:

Will Not Work:
CREATE USER adv_junk IDENTIFIED BY 7d326f328b296ed618d8;

Works:

CREATE USER adv_junk IDENTIFIED BY d326f328b296ed618d8;
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 15 2012
Added on Jul 18 2012
3 comments
11,083 views