I'd like to create users through procedure on another database via database link:
Here are the code which i used:
create or replace
PROCEDURE createuser(user_name in VARCHAR2, pass_word in VARCHAR2)
IS
BEGIN
dbms_utility.exec_ddl_statement@rahul('CREATE USER'||user_name||'IDENTIFIED BY'||pass_word||' DEFAULT TABLESPACE USERS PROFILE DEFAULT ACCOUNT UNLOCK');
END createuser;
/
when executing it i got an error:
ORA-00901: invalid CREATE command
ORA-06512: at "SYS.DBMS_UTILITY", line 574
ORA-06512: at "SYS.CREATEUSER", line 4
ORA-06512: at line 1
How to resolve it?