Oracle Usage

Accounts on Oracle (Version for everybody in the class with wpi accounts now exist. For documentation, remember to vist:

You will be using the oracle server on a ccc machine; thus first ssh or log onto one of the CCC machines (such as,

You need to follow the steps below in order to use the Oracle command_line interface, i.e., sqlplus.

0. You do:

ln -s /usr/local/bin/coraenv coraenv

This would create a soft link linking a file "coraenv" in your home directory to an oracle initialization file located at /usr/local/bin/. You only need to do this ONCE to create the file "coraenv".

Or, alternatively, you can also create a file yourself called ".cshrc", with the content:

setenv PATH .
setenv ORACLE_BASE /usr/local/oracle
setenv ORACLE_HOME /usr/local/oracle/product/10.1.0/db_1
setenv PATH ${PATH}:${ORACLE_HOME}/bin
setenv ORACLE_SID cs

But if you do above, you need to be very careful so not to put any extra blanks or other end-of-line symbols into your .cshrc file.

For the other steps, namely steps 1~4 below, you need to do them every time when you want to connect to Oracle.

1. Login to


2. Source the Oracle environment initialization file:

source coraenv

Or, alternatively, you could also have done
source .cshrc

This runs the initialization file that sets up some environment variables for Oracle. If it prompts "ORACLE_SID = [xxx]" where "xxx" is not "CS", answer "CS". If it prompts "ORACLE_SID = [CS]", just hit the ENTER key.

In 2007, we have oracle version of 10g, the path is:/usr/local/oracle10g/product/10.1.0/db_1/bin

3. You now can start using Oracle by giving:


You should get the response like:

SQL*Plus: Release - Production on Thu Sep 11 11:01:04 2006
Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.
Enter user-name:

4. Provide your username and password:

input your user name and password, as mentioned in class.

Now you should be at the SQL-Prompt and should be able to create tables, etc. We strongly suggest you change your password immediately after you login to Oracle for the first time, by issuing the command passwd at the SQL prompt.

5. NOTE: If you are using some Oracle client software, the tnsnames.ora entry for this Oracle server instance is:

CS =
      (ADDRESS = (PROTOCOL = TCP)(Host = oracle.WPI.EDU)(Port = 1521))
      (SID = CS)