Expired users in oracle

Montag, 08. Dezember 2014, 10:21 Uhr | roberto@vasquez-angel.de |

To view a list of users and their status use following SQL statement:

select username,expiry_date,account_status from dba_users;

To unlock a user:

alter user <USERNAME> identified by <PASSWORD> account unlock;

To unlock an expired system user on oracle 12c, you habe to specify the container:

alter session set container=CDB$ROOT;
alter user system identified by oracle container=all;

Otherwise you’ll get following error:

ORA-65066: The specified changed must apply to all containers