Solved

SQLPlus and Example Oracle Scripts

Posted on 2004-09-16
4
3,955 Views
Last Modified: 2012-06-27
Tutorials on Oracle's website assume that I'm already in SQL*Plus.  They tell me to execute some script.  The script then does a
CONNECT system@orc1.world

First of all how do I get into SQL*Plus when it prompts me for a username and password?   Which account should be used to run these examples?
0
Comment
Question by:lcor
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 23

Expert Comment

by:seazodiac
ID: 12079225
what sqlplus are you talking about?  GUI version (it's called sqlplusw only for windows) or command-line?

they are using Command-line sqlplus to do script execution.


you can execute script in one of two ways :

1. first log in to database via sqlplus

I assume you are in windows:

C:\>sqlplus "system/manager@orcl.world"

then

SQL>@<file_path_to_script_file>


2. you can also execute a sql script directly

C:\>sqlplus "system/manager@orcl.world" @<script_file_name>
0
 
LVL 15

Accepted Solution

by:
ishando earned 500 total points
ID: 12079918
Do:

c:\> sqlplus /nolog
SQL> @script

or

c:\> sqlplus /nolog @script
0
 

Expert Comment

by:Captive1180
ID: 12083356
If you say ,you are in oracle then, you must be getting a dialog box which asks for a username ,password and host string

So enter username-  scott  
password- tiger
host string - enter server name if you are on a client machine else leave it blank


or

So enter username-  system
password- manager
host string - enter server name if you are on a client machine else leave it blank

OR


Try executing the following command on the command prompt  depending on where oracle is installed ----

c:\ connect scott/tiger@servername

or

c:\ connect system/manager@servername

All the best
0
 

Author Comment

by:lcor
ID: 12086778
ishando's solution was what I was looking for because I needed a way to log into SQLPlus without specifying username and password.  The Oracle example scripts do that for me.
0

Featured Post

Secure Your Active Directory - April 20, 2017

Active Directory plays a critical role in your company’s IT infrastructure and keeping it secure in today’s hacker-infested world is a must.
Microsoft published 300+ pages of guidance, but who has the time, money, and resources to implement? Register now to find an easier way.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
From implementing a password expiration date, to datatype conversions and file export options, these are some useful settings I've found in Jasper Server.
This video shows information on the Oracle Data Dictionary, starting with the Oracle documentation, explaining the different types of Data Dictionary views available by group and permissions as well as giving examples on how to retrieve data from th…
This video shows syntax for various backup options while discussing how the different basic backup types work.  It explains how to take full backups, incremental level 0 backups, incremental level 1 backups in both differential and cumulative mode a…

756 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question