How to enter SQL statements? :
SQL*PLUS allow to types of command to entered at the prompt - SQL and
SQL*PLUS.
SQL commands include commands of ANSI/ISO SQL and extra commands
added to ANSI SQL by oracle.
The following are the rules to be followed while entering SQL commands.
- An SQL statement may be entered in multiple lines.
- It is not possible to break a word across lines.
- SQL statement must be terminated by semicolon (;).
The following is an example of SQL command.
What this command does is not
important at this moment.
In the above command, we entered the command in three lines. When you
enter semicolon and press enter key then SQL*PLUS will take it as the end of
the command. Also note that you have to press enter key at the end of each
line.
How to enter SQL*PLUS statements? : SQL*Plus statements are available only in SQL*PLUS. They are not part of
standard SQL. SQL*Plus commands are mainly used for two purposes – editing
SQL commands and formatting result of query.
The following rules are to be followed while entering these commands. :
- The entire command must be entered on a single line.
- No need to terminate command with semicolon (;).
- Commands can be abbreviated. However, the amount of abbreviation is
not fixed. Some commands are abbreviated to one letter some are
abbreviated to 2 and so on.
Common Errors :The following are the common errors that you get while you are trying to log
on to Oracle.
Ora-01017: invalid username/password; login denied
The reason for this error is that you have entered a username or password
that is not valid. Check whether username you are entering is really existing
and password is correctly typed. Sql*plus gives you three chances to type
username and password correctly. If you cannot log on successfully in three
chances then Sql*plus will exit. However, you can restart Sql*plus again.
ORA-01034: ORACLE not available : The reason for this message is that Oracle Instance is not up and running. You
have to first make sure you have started Oracle Instance. Actually there are a
few other problems that occurs when Oracle Instance has not started
successfully. If this is case in Oracle Server, notify administrator. If this is the
case with Personal Oracle, make sure you start database as mentioned in
“starting up database” section.
No comments:
Post a Comment