You can also provide both the username and password at the same time when connecting. To do this, at the command prompt, type CONNECT, followed by a space, followed by the username, followed by a forward slash "/", followed by the password. After typing the information, press Enter. After using the window, to close
it, type exit and press Enter.
The Structured Query Language Introduction After logging in, you can take actions. You do this using a
language named SQL. The Structured Query Language, known as SQL, is a
universal language used on various computer systems to create and manage databases. Like other
non-platform specific languages such as C/C++, Pascal, or Java, the SQL
you learn can be applied to various database systems. To adapt the SQL to
Oracle, the company developed PL/SQL. PL/SQL is the language used internally by
Oracle.
Although it highly adheres to the SQL standards, it has some
internal details that may not be applied to other database systems. The SQL Interpreter As a computer language, PL/SQL is used to give
instructions to an internal program called an interpreter. As we will
learn in various sections, you must make sure you give precise
instructions. SQL is
not case-sensitive. This means that CREATE,
create, and Create mean the same thing. It is a tradition to write SQL's
own words in uppercase. This helps to distinguish SQL instructions with
the words you use for your database. As we will learn in this and the other remaining lessons, you use
PL/SQL by writing statements. To help you with this, we saw that you can use a
DOS window or the Home page. Creating Comments in SQL Code Writing A comment is text that the SQL interpreter would not
consider as code. As such, a comment is written any way you like. What
ever it is made of would not be read. PL/SQL supports two types of comments. The
style of comment that starts with /* and ends with */ can be used.
To apply it, start a line with /*, include any kind of text you like, on
as many lines as you want. To close the commented section, type */. Here
is an example of a line of comment: A comment can also be spread on more than one line, like
a paragraph. Here is an example:
PL/SQL also supports the double-dash comment.
This comment applies to only one line of text. To use it, start the line
with --. Anything on the right side of -- is part of a comment and would
not be considered as code. Here is an example: The End of a Statement In SQL, after writing a statement, you can end it with
a semi-colon. In fact, if you plan to use many statements in one block,
you should end each with a semi-colon. When many statements are used, some of them must come after
others. |
|
|||||||||||||
|