I have installed Oracle 12c and I have trouble creating my first database and using it. I run the SQL developer and use the "HR" user but it keeps telling me that the account is locked. I searched for stackoverflow answers and official doctors and tried to unlock it:
password identified by ACCOUNT unblock ALTER USER HR;
But without success, I got the error ORA01918, which means that the user does not exist.
I tried to use the user created in the installation (SYSDBA as SYS), but then it says that the user / password is wrong. I'm pretty sure I installed Oracle 12c on my system properly, which is Windows 8.1 x64.
What should I do? Please help me.
Whatever I do not understand, is the weather or does not the "database" word match the "schema" of MySQL? "Connection" is to connect to a specific database, yes? Thank you.
How did you configure your database? Have you checked the option for pluggable database
? If so, please make sure that you do not enter PDB
and CDB
.
Please read.
By default, pre-installed
users such as SCOTT
, hr
etc not in the pluggable database
.
tnsnames.ora
To add PDB details, edit your tnsnames.ora file. For example,
PDBORCL = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP) (HOST = localhost) (port = 1521)) (CONNECT_DATA = (server = defined) (SERVICE_NAME = pdborcl ))
Open all PDBs
to open all / specific PDBs immediately after logon, after a STARTUP System level triggers in CDB.
Since, PDBs are not open with a CDB start-up:
Shut down immediately; start up; SQL & gt; V $ pdbs from SELECT name, open_mode; Name OPEN_MODE ------------------------------ ---------- PDB $ Seed Read Only PDBP6 Mounts < /> ", and then execute: Open the trigger after starting the database, open_pdbs start 'open all database executed immediately'; end open_pdbs ; SQLPLUS / AS SYSDBA The most common misconception is about using "SQLPLUS / AS SYSDBA".
Since We have checked the option to create a single CDB , then the "SQLPLUS / AS SYSDBA" command will always be logged in Usually the developers used to unlock the "SCOTT" account after logging in as a SYSDBA. But here's the trick: "SCOTT" and other samples Schema is in PDB and not in the CDB Therefore, you need to login into PDB as sysdba. sqlplus SYS / password @ PDBORLSssdbacxl> Optionally User recognized by Scott Account Tiger Lock; Sqlplus Scott / Tiger @ PDBCRL SQL & gt; Show users; USER is "SCOTT"
Comments
Post a Comment