Friday, May 5, 2017

Connect to the SQL Plus from command prompot

Do the following steps to start SQL*Plus and connect to the default database:
  1. Open a Windows command prompt.
  2. At the command-line prompt, enter the SQL*Plus command in the form:
    c:\> sqlplus
    
  3. When prompted, enter your Oracle9i username and password. If you do not know your Oracle9i username and password, ask your Database Administrator.
  4. SQL*Plus starts and connects to the default database.
    Now you can start entering and executing SQL, PL/SQL and SQL*Plus statements and commands at the SQL> prompt.
Do the following to start SQL*Plus and connect to a specified database other than the default:

  1. Start SQL*Plus and connect to the default database.
  2. Use the CONNECT command to specify the Oracle Net database alias (@connect_identifier) of the database you want to connect to. To do this enter the CONNECT command in the form:
    SQL> connect username/password@connect_identifier
    
    
    To hide your password, enter the CONNECT command in the form:
    SQL> connect username@connect_identifier
    
    
    You will be prompted to enter your password.
  3. Alternatively, to start SQL*Plus connected to a database other than the default, enter the SQL*Plus command in the form:
    c:\> sqlplus username/password@connect_identifier
    
    
    To hide your password, enter the SQL*Plus command in the form:
    c:\> sqlplus username@connect_identifier
    
    
    You will be prompted to enter your password.

No comments:

Post a Comment