What are the types of tables in Oracle?
In oracle we can create following type of tables :
1.
Simple Relational tables - with columns, these are the most conman tables in oracle. Relational tables can be either A
heap-organized table or An
index-organized table.
A
heap-organized table does
not store rows in any particular order means store the data in the
order in which we are inserting in the table.
An
index-organized table orders
rows according to the primary key values.
2.
Object tables – In object
tables each row represent an object. For object tables, we
first need to define the object type and then table based on the
object like -
CREATE
TYPE department_typ AS OBJECT ( d_name VARCHAR2(100), d_address
VARCHAR2(200) );
CREATE
TABLE departments_obj_t OF department_typ;
3.
Temporary tables – definition of temporary
table persists
in the same way as a permanent table definition, but the data exists
only for the duration of a transaction
or
session.
And data in temporary table is private to the session. Users can't
see the data across session even using the same temporary table for
their transaction.
4.
External table - is
a read-only table whose metadata is stored in the database but whose
data in stored outside the database in flat files.
5. Portioned Table - Partitioned tables
are decomposed
into smaller and more manageable pieces called partitions.
Each partition is an independent object with its own name and
optionally its own storage characteristics.
6.
Clustered table - is
a group of tables that share common columns and store related data in
the same blocks adjacent to the cluster key. The cluster
key is
the column or columns that the clustered tables have in common.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home