0
votes

I have just created a new user on an newly created Oracle 12C database and cannot use it to login from either SQL*Plus or SQL Developer. What am I doing wrong? I can connect as SYSTEM but not as NEWGUY.

-- logged in as SYSTEM....

alter session set CONTAINER=PDBNEW

create user NEWGUY identified by FRED
grant connect to NEWGUY

I can connect as system but trying to connect changing only the username and password results in failure. (ORA-91917: invalid username/password; login denied.

I can see NEWGUY in the DBA_USERS table.

I'll amend this if you need more information....

1
You should probably be granting session rather than connect, though connect should still work as far as I'm aware. What is your connect command - do you have the password case correct? - Alex Poole
Are you aware that passwords are case-sensitive by default? If you supply fred (instead of FRED) as the password during login, you'd get exactly that message. - a_horse_with_no_name
Are you attempting to connect to the right container? I think you should be doing connect newguy/FRED@pdbnew but I'm not sure. (I haven't started working with 12c yet but I think you might not be doing that; you know the alter session you did earlier doesn't affect what the connect is accessing?). - Alex Poole
I think you should grant create session GRANT CREATE SESSION TO NEWGUY; - Chamal Pradeep Rajapakse
Using an all-uppercase password doesn't disable the case sensitivity of the password check. If you set your password to FRED, you'll have to use FRED, not fred or Fred or ... (this is quite different from the rules for object names, where an all-uppercase name isn't sensitive even if quoted) - Frank Schmitt

1 Answers

0
votes

Remember everyone that if you create a PDB you have to open it and set it to read/write in order for it to be open for business.

ALTER PLUGGABLE DATABASE myPDBDatabase OPEN READ WRITE;