Hi all,
It's not clear in my mind, the difference between a segment and a extent. Somebody can give a definition of an SEGMENT versus an EXTENT versus an BLOCK?
Thanks.
Printable View
Hi all,
It's not clear in my mind, the difference between a segment and a extent. Somebody can give a definition of an SEGMENT versus an EXTENT versus an BLOCK?
Thanks.
Hi,
read the article at:
http://www.alise.lv/alise/technolog....ILE/defrag.pdf
Segments are the physical representation of the logical database objects. A segment is thus a subunit of a tablespace, and will be contained in a datafile. extents are subunits of a segment, and are defined as contiguous sets of Oracle blocks. Successive extents are not guaranteed to be contiguous, but within each extent the Oracle blocks are contiguous. A block is the unit of data that can be read or written to an Oracle data file, and is managed using PCT_FREE and PCT_USED, among others.
Thanks a lot guys,
So,
there are only one segment for an object.
That means than an segment can be spread on multiple files?
Not necessarily so. A table (object) can have partitions (subobjects), and partitions are segments. So with partitioned tables and indexes you have more than one segment for table/index.Quote:
Originally posted by m_d_marian
So,
there are only one segment for an object.
Yes.Quote:
That means than an segment can be spread on multiple files?
Good point J.
I went for the simple solution and ignored an important fact for larger/more complex systems.