1

I had to setup an Oracle environment. The stage is as follows: there are Oracle 11.2 client and 10g express server, the OS is Windows 7, 64-bit. I have the ORACLE_HOME, ORACLE_SID and PATH env. variables set correctly.

I have to connect to the server via the 11.2 client.

When I type in cmd:

  1. sqlplus, then
  2. username, then
  3. password

I get ORA-12560 and after 3 attempts I get disconnected.

but if I type the following:

sqplplus username/password@xe 

I get connected without any further objection from Oracle.

Have you had similar experience? Do you have an idea why this behavior is exhibited?

1 Answer 1

1

ORA-12560

ORA-12560 is TNS Protocol adapter error which happens if the TNS listener service is incorrectly configured or not running. When you type sqlplus and enter only the username & password, Oracle assumes the default TNS name of orcl which is not configured in your system.

When you type in

sqplplus username/password@xe 

you're explicitly giving the TNS name as xe which is then resolved by looking up the tnsnames.ora file in %oracle_home%\network\admin directory and then connects to that instance of the database

2
  • Thank you! Can you just clarify what's orcl in "assumes the default TNS name of orcl"?
    – karla
    Dec 19, 2011 at 18:55
  • @karla orcl is the default name of the service for an Oracle instance, much like how xe is the name of the service in your case
    – Sathyajith Bhat
    Dec 21, 2011 at 12:07

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .