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!

Lock/Unlock users

400830Aug 6 2003 — edited Aug 7 2003
Hi,
I have a procedure that lock/unlock users.
----------
PROCEDURE "LOCKUSER" (PNAME IN VARCHAR)
IS
SQLTEXTO VARCHAR2(200);

BEGIN
SQLTEXTO := 'ALTER USER ' || PNAME || ' ACCOUNT UNLOCK';
EXECUTE IMMEDIATE SQLTEXTO;
END;
-----------
When I use this procedure that start with number happen this error:

SQL> exec lockuser('049CHAFIC');
BEGIN lockuser('049CHAFIC'); END;

*
ERRO na linha 1:
ORA-01935: missing user or role name
ORA-06512: at "ADVDB.LOCKUSER", line 7
ORA-06512: at line 1

but if I use only character that don't start with number then there isn't error.

What's happening?

thanks!!

Omar
oteles@redegazeta.com.br
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 4 2003
Added on Aug 6 2003
3 comments
555 views