Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 698
  • Last Modified:

SQLPlus password entry

I recently installed Oracle 12c on a WIndows server for an application which uses it, and created two databases with SYSTEM password ending with an exclamation mark. I am now trying to get back into the database some weeks later using SQLPlus to do some administration, and keep getting "ORA-01017: invalid username/password; logon denied" messages.

I know the passwords have not changed as if I use the Oracle Administration Assistant for Windows I can connect to both databases by entering SYSTEM and the appropriate password, so the issue must be related to the ! character

I have tried putting double quotes round the password but this makes no difference - any ideas?
0
Richard Jebb
Asked:
Richard Jebb
1 Solution
 
DavidSenior Oracle Database AdministratorCommented:
Confirm you have correctly set the ORACLE_SID value.  Since you are trying a different method to connect, that's easy to overlook.

Confirm your typing (sorry, it does happen).

Provide us with the full command you're trying (mask the password)

Try an interactive session with one string at a time, for example:
$ORACLE_HOME/bin/sqlplus
at user prompt, just the username
at password prompt, just the password
0
 
Haris DjulicCommented:
Issue is related to exclamation mark for sure since :

Nonquoted identifiers can contain only alphanumeric characters from your database character set and the underscore (_), dollar sign ($), and pound sign (#). Database links can also contain periods (.) and "at" signs (@). Oracle strongly discourages you from using $ and # in nonquoted identifiers.

You can connect to database as Sys from sqlplus and change password...
0
 
slightwv (䄆 Netminder) Commented:
I just created a user on my 12c system and had to use double quotes around the password.

Make sure the character case is the same.

When in doubt, change the system passwords.

SQL> create user bob identified by "password!";

User created.

SQL> grant create session to bob;

Grant succeeded.

SQL>

Open in new window


The connect:
C:\>sqlplus bob/"password!"@mydb

SQL*Plus: Release 12.1.0.1.0 Production on Thu Sep 25 08:37:26 2014

Copyright (c) 1982, 2013, Oracle.  All rights reserved.

Last Successful login time: Thu Sep 25 2014 08:36:00 -04:00

Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.1.0 - 64bit Production
With the Partitioning, OLAP, Advanced Analytics and Real Application Testing opt
ions

SQL>

Open in new window

0
 
Richard JebbAuthor Commented:
I have just actually figured it out, I was following someone else's instructions for setting archivelog mode on which requires DBA mode access. I have been trying to login as SYSTEM AS SYSDBA rather than SYS AS SYSDBA. But I do need to put double quotes round the password for it to work, ie

sqlplus SYS/"<pwd ending in !>"@<database> AS SYSDBA
0
 
Richard JebbAuthor Commented:
I fugured out the answer myself, and the expert advice did not assist me in reaching the answer
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now