lec05.365 - Fall 2007 CPE/CSC 365 Introduction to Database...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: . . Fall 2007 CPE/CSC 365: Introduction to Database Systems Alexander Dekhtyar . . Oracle’s SQL*plus client SQL*plus SQL*plus is an interactive, command-line client for the Oracle DBMS . Upon login, you get a prompt at which you can enter any SQL command. The com- mand will be immediately passed to the DBMS, and the results will be displayed back. In addition, SQL*plus has a number of internal commands that control its behavior. Some of these commands provide directions for output formatting, and work with SQL and SQL/PL scripts in SQL*plus ’s memory. Others enable the users to set up and run SQL and SQL/PL code from existing files in a batch mode. Setup Instructions These setup instructions refer to running SQL*plus from the CSL linux machines, such as the ones found in the database lab, 14-302. All CSL machines have the following environment variable defined: ORACLE_HOME=/app/oracle/product/10.2.0/client_1 This variable specifies the path to the directory where Oracle is installed on the system. The binaries for all Oracle software are located in /app/oracle/product/10.2.0/client_1/bin or $ORACLE_HOME/bin You can add $ORACLE_HOME/bin to your PATH environment variable (in csh/tsch , the command is setenv PATH ‘echo $PATH‘:$ORACLE_HOME/bin ). In the instructions below, it is assumed that $ORACLE_HOME/bin is in your PATH . sqlplus login There are two Oracle DBMS servers running on the CS system. One of these servers, ora10g is used for instruction in our class. Each of you will be issued 1 a loginid for this server. Your loginids will have the format STx or STxx where "x"/"xx" is a number between 1 and 50. Initial passwords will be issued to you. Upon your first login, you will be asked to change them. Note: It should be obvious, but it bears repeating: your Oracle accounts (and passwords) are independent of yor CSC lab accounts. To start SQL*plus , from the command line, type > sqlplus In the login prompt that appears enter your user id (e.g., “ST38”) followed by the name of the Oracle server on which you are logging: ora10g . The dialog will proceed as follows: > sqlplus SQL*Plus: Release - Production on Sun Sep 30 16:43:16 2007 Copyright (c) 1982, 2005, Oracle. All rights reserved. Enter user-name: [email protected] Enter password: Enter your Oracle DBMS password at the prompt. Once your login is authentificated, the SQL*plus prompt will appear. You many now begin your session. SQL*plus commands SQL statements SQL*plus allows you to enter any valid SQL statement. Large SQL statements can be split into multiple lines (press ”Enter” key and continue). To complete an SQL statement do one of the following: • type ";" and hit "Enter" . SQL*plus will send the SQL statement to the DBMS server immediately....
View Full Document

This note was uploaded on 05/19/2008 for the course CSC 365 taught by Professor Dekhtyar during the Spring '08 term at Cal Poly.

Page1 / 8

lec05.365 - Fall 2007 CPE/CSC 365 Introduction to Database...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online