Using Oracle
dbms_rowid
Bigfile
Tablespace Rowid Format
In a bigfile tablespace, there is only one
file that always has a relative file number
of 1024. A bigfile tablespace has a
three-piece format, OOOOOOLLLLLLLLLRRR, in
which
LLLLLLLLL is used to denote the block
number. The concatenation of FFF and BBBBBB
makes the encoded block number. For BFTs,
the only supported way of getting components
of extended rowids is to use the Oracle
DBMS_ROWID package.
Here is an example on how to use the Oracle
dbms_rowid package to retrieve rowid
information:
select dbms_rowid. rowid_relative_fno(rowid,
'BIGFILE')
bigfile_rowid,
dbms_rowid. rowid_relative_fno(rowid, 'SMALLFILE')
smallfile_rowid,
first_name, last_name
FROM hr.employees
where rownum < 3;
BIGFILE_ROWID SMALLFILE_ROWID FIRST_NAME
LAST_NAME
------------- ---------------
-------------------- ---------
1024 4 Ellen Abel
1024 4 Sundar Ande
The rowid can be easily manipulated with the
Oracle DBMS_ROWID package (.If, against
Oracle admonitions not to, you used rowid in
your Oracle7 application, you will have to
familiarize yourself with this package..
Old rowids (called restricted rowids) will
be automatically converted to the new format
if:
You use export/import to move data.
You use the migration utility.
You use the ODMA to upgrade to 9i.
If you used rowids in your Oracle7
application and stored them as columns in
other tables, then these columns will have
to be manually changed to the new format
using the Oracle DBMS_ROWID package. If a
column in a table has been designated as a
datatype of rowid, it will be altered to
accept the new format during migration; this
will not affect the data in the column.
|
|