The Drop Clause
The Drop clause is used to remove a definition from the database. It is most commonly used to
remove a table from a database but can also be used for removing several other constructs. In
2.0 it can be used to remove the definition of an index, a sequence, or a table. It should be
noted that
dropping
a table or an index removes the data associated with that object as well as
the definition.
The syntax of the drop clause as well as examples of its use are given below.
DROP TABLE table_name
DROP INDEX index_name FROM table_name
DROP SEQUENCE FROM table_name
for example
DROP TABLE emp_details
DROP INDEX idx1 FROM emp_details
DROP SEQUENCE FROM emp_details
The Insert Clause
Unlike ANSI SQL, you cannot nest a select within an insert (i.e. you cannot insert the data
returned by a select). If you do not specify the field names they will be used in the order they
were defined you must specify a value for every field if you do this.
INSERT INTO table_name [ ( column [ , column ]** ) ]
G
VALUES (value [, value]** )
for example
INSERT INTO emp_details
G
(first_name, last_name, dept, salary)
VALUES ( David , Hughes , Development , 12345 )
INSERT INTO emp_details
VALUES ( David , Hughes , Development , 12345 )
The number of values supplied must match the number of columns.
The Select Clause
The SELECT offered by mSQL lacks some of the features provided by the standard SQL
specification. Development of mSQL 2 is continuing and some of this missing functionality
will be made available in the next beta release. At this point in time, mSQL s select does not
provide
Nested selects
G
Implicit functions (e.g. count(), avg() )
G
It does however support:
Joins including table aliases
G
<
New Page 1
Godaddy Web Hosting