Tuesday, June 26, 2012

Large Objects

There are four data types  in this catagory

Clob -->character large objects (cannot store images)
Blob -->binary large objects(can be used to store anything like image,media files etc)
Nclob-->multibyte character set
Bfile -->this also can store any objects like image etc
clob,blob,nclob are stored inside the database.
Bfile is external to the database and the table only contains a pointer to the location of the file.
Eg:
crate table t1(col1 bfile);
insert into t1 values(bfilename('p_dir','a.txt'));
select * form t1;
p_dir/a.txt will be the o/p

The Bfile is read only .
The others large objects are editable.


LONG:

A table can have only one long column.
The datas are stored in the same block .

LOB:

Any number of LOB columns possible.
The datas can be kept anywhere in the tbl space in any other segments also.















No comments:

Post a Comment