Database/Oracle
user 생성과 테이블스페이스 지정 및 권한설정
denodo
2013. 1. 13. 11:12
Oracle을 사용하다보면 종종 유저 Lock이 걸리곤 한다.
일단 root 권한인 sys로 oracle에 접속하자
sqlplus sys/manager as sysdba;
유저 락 해제
alter user soctt2 account unlock;
유저의 락을 해제하면 비번과 권한설정을 새로 해주어야 한다.
alter user scott2 identified by tiger2;
grant create session to scott2;
grant create sequence to scott2;
grant create table to scott2;
grant drop any table to scott2;
그리고 테이블을 생성/삭제 하려는데, 테이블스페이스의 권한설정이 새로 생성한 scott2에게 없다고 에러를 낸다.
그럴 때는 scott2 유저에게 테이블스페이스의 권한까지 주자.
alter user scott2 quota unlimited on webacc;
이렇게하면 에러가 나지 않을 것이다