Data block 內部結構的解析(轉載gyj_hobby的文章)
Data block 內部結構的解析(轉載gyj_hobby的文章)
地址: http://www.itpub.net/thread-1747870-1-1.html
帖子共四部分,回答皆是 gyj_hobby , 感謝gyj_hobby的分享與答疑
第一部分:
Data Block 是資料庫中最小的I/O單元,下面我來簡單介紹下資料塊的基本結構。
OK !跟著我一步步實驗:
一、建表空間
SQL>create tablespace tp1 datafile '/oradata/bxocp/tp01.dbf' size 10M;
二、建使用者及授權
SQL>create user gyj identified by gyj default tablespace tp1;
SQL>grant dba to gyj;
三、建表
SQL>conn gyj/gyj
SQL>create table t1 (id int,name varchar2(100));
四、插入一行資料
SQL>insert into t1 values(1,'AAAAA');
SQL>commit;
五、手動發生一個檢查點,使上面一行資料寫到資料檔案
alter system checkpoint;
六、查這行資料所在的檔案號和塊號
SQL>col name for a10
SQL>select id,name,dbms_rowid.rowid_relative_fno(rowid) file#,dbms_rowid.rowid_block_number(rowid) block# from t1;
ID NAME FILE# BLOCK#
---------- --------- ---------- ----------
1 AAAAA 6 135
七、轉儲6號檔案135號塊,新開個視窗
[ oracle@guoyj ~]$ sqlplus / as sysdba
SQL> alter system dump datafile 6 block 135;
八、找到轉儲的檔案
SQL> show parameter dump
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
background_core_dump string partial
background_dump_dest string /u01/app/oracle/diag/rdbms/bxo
cp/bxocp/trace
再開一新視窗
[oracle@guoyj ~]$ cd /u01/app/oracle/diag/rdbms/bxocp/bxocp/trace
[oracle@guoyj trace]$ ls -lFtr
下面這個跟蹤日誌就是6號檔案135號塊轉儲出來的資料塊資訊
-rw-r----- 1 oracle oinstall 3363 Dec 11 18:02 bxocp_ora_5429.trc -
九、分析資料塊結構
[oracle@guoyj trace]$ vi bxocp_ora_5429.trc
Trace file /u01/app/oracle/diag/rdbms/bxocp/bxocp/trace/bxocp_ora_5429.trc
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
ORACLE_HOME = /u01/app/oracle/product/11.2.0
System name: Linux
Node name: guoyj
Release: 2.6.18-128.el5
Version: #1 SMP Wed Dec 17 11:41:38 EST 2008
Machine: x86_64
VM name: VMWare Version: 6
Instance name: bxocp
Redo thread mounted by this instance: 1
Oracle process number: 28
Unix process pid: 5429, image: oracle@guoyj (TNS V1-V3)
*** 2012-12-11 18:02:31.307
*** SESSION ID:(29.15) 2012-12-11 18:02:31.307
*** CLIENT ID:() 2012-12-11 18:02:31.307
*** SERVICE NAME:(SYS$USERS) 2012-12-11 18:02:31.307
*** MODULE NAME:(sqlplus@guoyj (TNS V1-V3)) 2012-12-11 18:02:31.307
*** ACTION NAME:() 2012-12-11 18:02:31.307
Start dump data blocks tsn: 7 file#:6 minblk 135 maxblk 135
Block dump from cache:
Dump of buffer cache at level 4 for tsn=7 rdba=25165959
BH (0x7f3f6958) file#: 6 rdba: 0x01800087 (6/135) class: 1 ba: 0x7f33a000
set: 3 pool: 3 bsz: 8192 bsi: 0 sflg: 1 pwc: 103,28
dbwrid: 0 obj: 76987 objn: 76987 tsn: 7 afn: 6 hint: f
hash: [0x908b5100,0x908b5100] lru: [0x7f3f6910,0x7f3f6b70]
ckptq: [NULL] fileq: [NULL] objq: [0x7f3f6938,0x8d148e00] objaq: [0x7f3f6948,0x8d148df0]
st: XCURRENT md: NULL fpin: 'ktspbwh2: ktspfmdb' tch: 3
flags: block_written_once redo_since_read
LRBA: [0x0.0.0] LSCN: [0x0.0] HSCN: [0xffff.ffffffff] HSUB: [1]
Block dump from disk:
buffer tsn: 7 rdba: 0x01800087 (6/135) scn: 0x0000.0015a3eb seq: 0x01 flg: 0x06 tail: 0xa3eb0601frmt: 0x02 chkval: 0xec19 type: 0x06=trans data |
Hex dump of block: st=0, typ_found=1
Dump of memory from 0x00002B70E9566A00 to 0x00002B70E9568A00
2B70E9566A00 0000A206 01800087 0015A3EB 06010000 [................]
2B70E9566A10 0000EC19 00000001 00012CBB 0015A3EA [.........,......]
2B70E9566A20 00000000 0032F802 01800080 000F0004 [......2.........]
2B70E9566A30 00000346 00C00793 002200BB 00002001 [F.........".. ..]
2B70E9566A40 0015A3EB 00000000 00000000 00000000 [................]
2B70E9566A50 00000000 00000000 00000000 00000000 [................]
2B70E9566A60 00000000 00010100 0014FFFF 1F781F8C [..............x.]
2B70E9566A70 00001F78 1F8C0001 00000000 00000000 [x...............]
2B70E9566A80 00000000 00000000 00000000 00000000 [................]
Repeat 502 times
2B70E95689F0 0202012C 410502C1 41414141 A3EB0601 [,......AAAAA....]
1. 資料塊頭
Block header dump: 0x01800087 Object id on Block? Y seg/obj: 0x12cbb csc: 0x00.15a3ea itc: 2 flg: E typ: 1 - DATA brn: 0 bdba: 0x1800080 ver: 0x01 opc: 0 inc: 0 exflg: 0 |
seg/obj: 0x12cbb --16 進位制轉成10進位制76987
SQL> select object_id from dba_objects where object_name='T1' and wner='GYJ';
OBJECT_ID
----------
76987
csc: 0x00.15a3ea --cleanoutSCN, 塊清除時的SCN
itc: 2 -- 指向第二個事務槽
flg: E -- 指用的是ASSM,如果是 O 表示用的是free list
typ: 1 - DATA -- 型別是資料
2. 事務槽
Itl Xid Uba Flag Lck Scn/Fsc 0x01 0x0004.00f.00000346 0x00c00793.00bb.22 --U- 1 fsc 0x0000.0015a3eb 0x02 0x0000.000.00000000 0x00000000.0000.00 ---- 0 fsc 0x0000.00000000 |
Itl: ITL 事務槽號的流水編號
Xid :transac[X]tion identified(事務ID),由und的段號+undo的槽號+undo槽號的覆蓋次數三部分組成
Uba :undo block address記錄了最近一次的該記錄的前映象(修改前的值)
Flag :C是提交,U是快速提交,---是未提交
Lck :鎖住了幾行資料,對應有幾個行鎖
Scn/Fsc :Scn=SCN of commited TX; Fsc=Free space credit(bytes)
這裡fsc 0x0000.0015a3eb是指提交的scn,這個值大於上次清除塊時的scn=csc: 0x00.15a3ea(此scn是這個塊中最小的SCN of commited)
3. 使用者資料頭
bdba: 0x01800087 data_block_dump,data header at 0x2b70e9566a64 =============== tsiz: 0x1f98 hsiz: 0x14 pbl: 0x2b70e9566a64 76543210 flag=-------- ntab=1 nrow=1 frre=-1 fsbo=0x14 fseo=0x1f8c avsp=0x1f78 tosp=0x1f78 0xe:pti[0] nrow=1 offs=0 0x12:pri[0] offs=0x1f8c |
bdba: 0x01800087 -- 資料塊的地址:16進位制轉成2進製取前10位二進位制為檔案號0000 0001 1000 ..... 0000000110=5號檔案,後面剩於的部分表示塊號,0X87轉成10進製為135號塊
tsiz: 0x1f98 --top of size 塊的總大小即8088個位元組
hsiz: 0x14 --Data header size 資料頭大小即20個位元組
pbl: 0x2b70e9566a64 --Pointer to buffer holding the block
76543210
flag=-------- N=pcrfree hit(clusters);F=do not put on free list;K=flushable cluster keys
ntab=1 -- 表示這個塊的資料在一個表(如果是聚簇表就有可能是2或2以上)
nrow=1 -- 表示這個表有一行資料
frre=-1 -- The first free row entry in the row directory =you have to add one
fsbo=0x14 -- Free space begin offset 可以存放資料空間的起始位置
fseo=0x1f8c -- Free space end offset 可以存放資料空間的結束位置
avsp=0x1f78 --Available space for new entries
tosp=0x1f78 --Total space
0xe:pti[0] nrow=1 offs=0 --Table directory, 整個表的開始,共一行資料
0x12:pri[0] offs=0x1f8c --Row index ,行的開始,第一行的位置
4. 使用者資料
block_row_dump: tab 0, row 0, @0x1f8c tl: 12 fb: --H-FL-- lb: 0x1 cc: 2 col 0: [ 2] c1 02 col 1: [ 5] 41 41 41 41 41 end_of_block_dump End dump data blocks tsn: 7 file#: 6 minblk 135 maxblk 135 |
tab 0, row 0, @0x1f8c -- 第一個表第一行的位置
tl: 12 fb: --H-FL-- lb: 0x1 cc: 2 -- 行頭,tl: 12行長度12個位元組,
fb: (Flag byte)--H-FL 指H(Head piece of row)F(First data piece) L(Last data piece)
lb: 0x1 --Lock byte 和上面的ITL的lck相對應,表示這行是否被lock了
cc: 2 -- 表示有兩列,即這個表有兩個欄位
col 0: [ 2] c1 02 -- 第一行的第一個欄位長度和值
col 1: [ 5] 41 41 41 41 41 -- 第一行的第二個欄位長度和值
把字元轉成16進位制
SQL> select * from t1;
ID NAME
------ ---- -----
1 AAAAA
SQL> select dump(01,'16') from dual;
DUMP(01,'16')
-----------------
Typ=2 Len=2: c1,2
SQL> select dump('AAAAA','16') from dual;
DUMP('AAAAA','16')
----------------------------
Typ=96 Len=5: 41,41,41,41,41
反過來把16進位制轉成字元
SQL> select chr(to_number(substr(replace('41 41 41 41 41',' '),2*rownum-1,2),'xxxxxxxx')) from dba_objects where rownum<=5;
CH
--
A
A
A
A
A
不過對數值型別的不能這樣轉化,要寫過比較複雜的過程把各種字元都考慮進去。。。
資料塊的最後四位元組tail: 0xa3eb0601=scnBASE+flg+seq,如果不相等會報塊損壞!!!
scn: 0x0000.0015a3eb seq: 0x01 flg: 0x06
第二部分:
flg: E --
指用的是ASSM,如果是O表示用的是free list
這個確認嗎?
是的,我實驗一個MSSM的表空間給你看
SQL> create tablespace tp2 datafile '/oradata/bxocp/tp2.dbf' size 10M segment space management manual;
Tablespace created.
SQL> show user;
USER is "GYJ"
SQL> create table t2 (id int,name varchar2(10)) tablespace tp2;
Table created.
SQL> insert into t2 values(2,'BBBBB');
1 row created.
SQL> commit;
Commit complete.
SQL> alter system checkpoint;
System altered.
SQL> select dbms_rowid.rowid_relative_fno(rowid),dbms_rowid.rowid_block_number(rowid) from t2;
DBMS_ROWID.ROWID_RELATIVE_FNO(ROWID) DBMS_ROWID.ROWID_BLOCK_NUMBER(ROWID)
------------------------------------ ------------------------------------
7 129
SQL> alter system dump datafile 7 block 129;
System altered.
vi vi bxocp_ora_29633.trc
轉儲部分內容:看紅色字型
Object id on Block? Y
seg/obj: 0x12ccb csc: 0x00.16ee66 itc: 2 flg: O typ: 1 - DATA
fsl: 0 fnx: 0x0 ver: 0x01
Itl Xid Uba Flag Lck Scn/Fsc
0x01 0x0008.009.00000414 0x00c00130.00b8.03 --U- 1 fsc 0x0000.0016ee67
0x02 0x0000.000.00000000 0x00000000.0000.00 ---- 0 fsc 0x0000.00000000
bdba: 0x01c00081
data_block_dump,data header at 0x2b8e96fa2a5c
===============
tsiz: 0x1fa0
hsiz: 0x14
pbl: 0x2b8e96fa2a5c
76543210
flag=--------
ntab=1
nrow=1
frre=-1
fsbo=0x14
fseo=0x1f94
avsp=0x1f80
tosp=0x1f80
0xe:pti[0] nrow=1 offs=0
0x12:pri[0] offs=0x1f94
block_row_dump:
tab 0, row 0, @0x1f94
tl: 12 fb: --H-FL-- lb: 0x1 cc: 2
col 0: [ 2] c1 03
col 1: [ 5] 42 42 42 42 42
end_of_block_dump
End dump data blocks tsn: 8 file#: 7 minblk 129 maxblk 129
查ASSM/MSSM的表空間
SQL> select tablespace_name,SEGMENT_SPACE_MANAGEMENT from dba_tablespaces;
TABLESPACE_NAME SEGMEN
------------------------------ ------
SYSTEM MANUAL
SYSAUX AUTO
UNDOTBS1 MANUAL
TEMP MANUAL
USERS AUTO
EXAMPLE AUTO
TP1 AUTO
TP2 MANUAL
第三部分:
cc59
發表於 2012-12-15 21:20
o: on free list
E: bitmap seg
Object id on Block? Y
seg/obj: 0x12cbb csc: 0x00.15a3ea itc: 2 flg: E typ: 1 - DATA
brn: 0 bdba: 0x1800080 ver: 0x01 opc: 0
inc: 0 exflg: 0
資料塊的分類(class#):
1: data block
2: sort block
4: segment header block
8: 1st level bmp block
9: 2nd level bmp block
10: 3rd level bmp block
flg indicates that the block is on a freelist.Otherwise the flag is 9i 的ASSM的情況下這個值為E
note:when looking at blocks stored in tablespaces using auto segment space management,the freelist slot(fsl) and next block pointer(fnx) are replaced withr dba range number,opcode,first bitmap address and incarnation number of the bock
第四部分:
vage
發表於 2012-12-15 22:48
既然已經走到這一步,LZ再為大家總結下塊內空間的使用規則吧,比如有A、B、C三行,B行被Update,空間增大, ...
1.
建立表並插入三行記錄
SQL> create table t1 (id varchar2(10),name varchar2(1000)) pctfree 98;
Table created.
SQL> insert into t1 values(1,'A');
1 row created.
SQL> insert into t1 values(2,'B');
1 row created.
SQL> insert into t1 values(3,'C');
1 row created.
SQL> commit;
Commit complete.
SQL> alter system checkpoint;
System altered.
SQL> select id,dbms_rowid.rowid_relative_fno(rowid) file#,dbms_rowid.rowid_block_number(rowid)
block#,dbms_rowid.rowid_row_number(rowid) row# from t1;
ID FILE# BLOCK# ROW#
---------- ---------- ---------- ----------
1 6 327 0
2 6 327 1
3 6 327 2
2.再開一個視窗轉儲6號檔案327號塊
SQL> SQL> alter system dump datafile 6 block 327;
System altered.
3.dump出的內容如下:
Block header dump: 0x01800147
Object id on Block? Y
seg/obj: 0x12dd5 csc: 0x00.54bdd5 itc: 2 flg: E typ: 1 - DATA
brn: 0 bdba: 0x1800140 ver: 0x01 opc: 0
inc: 0 exflg: 0
Itl Xid Uba Flag Lck Scn/Fsc
0x01 0x0005.008.000009c2 0x00c000c5.00e4.34 --U- 3 fsc 0x0000.0054bde0
0x02 0x0000.000.00000000 0x00000000.0000.00 ---- 0 fsc 0x0000.00000000
bdba: 0x01800147
data_block_dump,data header at 0x2b9fde2d9a64
===============
tsiz: 0x1f98
hsiz: 0x18
pbl: 0x2b9fde2d9a64
76543210
flag=--------
ntab=1
nrow=3
frre=-1
fsbo=0x18
fseo=0x1f83
avsp=0x1f65
tosp=0x1f65
0xe:pti[0] nrow=3 offs=0
0x12:pri[0] offs=0x1f91
0x14:pri[1] offs=0x1f8a
0x16:pri[2] offs=0x1f83
block_row_dump:
tab 0, row 0, @0x1f91
tl: 7 fb: --H-FL-- lb: 0x1 cc: 2
col 0: [ 1] 31
col 1: [ 1] 41
tab 0, row 1, @0x1f8a
tl: 7 fb: --H-FL-- lb: 0x1 cc: 2
col 0: [ 1] 32
col 1: [ 1] 42
tab 0, row 2, @0x1f83
tl: 7 fb: --H-FL-- lb: 0x1 cc: 2
col 0: [ 1] 33
col 1: [ 1] 43
end_of_block_dump
End dump data blocks tsn: 7 file#: 6 minblk 327 maxblk 327
4.接著修改id=2這行,把原來1個B改成100個B,使行長度變長,觀察rowid是不是會變?
SQL> update t1 set name=lpad('B',100,'B') where id=2;
1 row updated.
SQL> commit;
Commit complete.
SQL> alter system checkpoint;
System altered.
SQL> select id,dbms_rowid.rowid_relative_fno(rowid) file#,dbms_rowid.rowid_block_number(rowid)
block#,dbms_rowid.rowid_row_number(rowid) row# from t1;
ID FILE# BLOCK# ROW#
---------- ---------- ---------- ----------
1 6 327 0
2 6 327 1
3 6 327 2
5.再次dump
Object id on Block? Y
seg/obj: 0x12dd5 csc: 0x00.54befa itc: 2 flg: E typ: 1 - DATA
brn: 0 bdba: 0x1800140 ver: 0x01 opc: 0
inc: 0 exflg: 0
Itl Xid Uba Flag Lck Scn/Fsc
0x01 0x0005.008.000009c2 0x00c000c5.00e4.34 C--- 0 scn 0x0000.0054bde0
0x02 0x0009.015.000009cb 0x00c00519.010f.01 --U- 1 fsc 0x0000.0054befc
bdba: 0x01800147
data_block_dump,data header at 0x2b52b8bf4a64
===============
tsiz: 0x1f98
hsiz: 0x18
pbl: 0x2b52b8bf4a64
76543210
flag=--------
ntab=1
nrow=3
frre=-1
fsbo=0x18
fseo=0x1f19
avsp=0x1f04
tosp=0x1f04
0xe:pti[0] nrow=3 offs=0
0x12:pri[0] offs=0x1f91
0x14:pri[1] offs=0x1f19
0x16:pri[2] offs=0x1f83
block_row_dump:
tab 0, row 0, @0x1f91
tl: 7 fb: --H-FL-- lb: 0x0 cc: 2
col 0: [ 1] 31
col 1: [ 1] 41
tab 0, row 1, @0x1f19
tl: 106 fb: --H-FL-- lb: 0x2 cc: 2
col 0: [ 1] 32
col 1: [100]
42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42
42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42
42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42
42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42
tab 0, row 2, @0x1f83
tl: 7 fb: --H-FL-- lb: 0x0 cc: 2
col 0: [ 1] 33
col 1: [ 1] 43
end_of_block_dump
End dump data blocks tsn: 7 file#: 6 minblk 327 maxblk 327
對修改前B值的兩次dump的內容比較
修改前
tab 0, row 1, @0x1f8a
tl: 7 fb: --H-FL-- lb: 0x1 cc: 2
col 0: [ 1] 32
col 1: [ 1] 42
修改後
tab 0, row 1, @0x1f19
tl: 106 fb: --H-FL-- lb: 0x2 cc: 2
col 0: [ 1] 32
col 1: [100]
42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42
42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42
42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42
42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42 42
修改前和修改後row=1,說明行號都沒變。即rowid沒變!但他們在塊中的偏移量(@0x1f8a,@0x1f19)變了?
再來個實驗,驗證一下行遷移,rowid會不會變?把A值再加大。
1.重新建個表,插入四行資料
SQL> drop table t2;
Table dropped.
SQL> create table t2 (id varchar2(10),name varchar2(4000));
Table created.
SQL> insert into t2 values(1,lpad('A',2000,'A'));
1 row created.
SQL> insert into t2 values(2,lpad('B',2000,'B'));
1 row created.
SQL> insert into t2 values(3,lpad('C',2000,'C'));
1 row created.
SQL> insert into t2 values(4,lpad('D',1000,'D'));
1 row created.
SQL> commit;
Commit complete.
SQL> alter system checkpoint;
System altered.
SQL> select id,dbms_rowid.rowid_relative_fno(rowid),dbms_rowid.rowid_block_number(rowid),dbms_rowid.rowid_row_number(rowid) from t2;
ID DBMS_ROWID.ROWID_RELATIVE_FNO(ROWID) DBMS_ROWID.ROWID_BLOCK_NUMBER(ROWID) DBMS_ROWID.ROWID_ROW_NUMBER(ROWID)
---------- ------------------------------------ ------------------------------------ ----------------------------------
1 6 359 0
2 6 359 1
3 6 359 2
4 6 359 3
2.轉儲6號檔案的359號塊
alter system dump datafile 6 block 359;
轉儲的內容,取A的dump資訊:
data_block_dump,data header at 0x2adb08d6ba64
===============
tsiz: 0x1f98
hsiz: 0x1a
pbl: 0x2adb08d6ba64
76543210
flag=--------
ntab=1
nrow=4
frre=-1
fsbo=0x1a
fseo=0x420
avsp=0x406
tosp=0x406
0xe:pti[0] nrow=4 offs=0
0x12:pri[0] offs=0x17c0
0x14:pri[1] offs=0xfe8
0x16:pri[2] offs=0x810
0x18:pri[3] offs=0x420
block_row_dump:
tab 0, row 0, @0x17c0
tl: 2008 fb: --H-FL-- lb: 0x1 cc: 2
col 0: [ 1] 31
col 1: [2000]
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
3.加大A值
SQL> update t2 set name=lpad('A',4000,'A') where id=1;
1 row updated.
SQL> commit;
Commit complete. SQL> alter system checkpoint;
System altered.
SQL> select id,dbms_rowid.rowid_relative_fno(rowid),dbms_rowid.rowid_block_number(rowid),dbms_rowid.rowid_row_number(rowid) from t2;
ID DBMS_ROWID.ROWID_RELATIVE_FNO(ROWID) DBMS_ROWID.ROWID_BLOCK_NUMBER(ROWID) DBMS_ROWID.ROWID_ROW_NUMBER(ROWID)
---------- ------------------------------------ ------------------------------------ ----------------------------------
1 6 359 0
2 6 359 1
3 6 359 2
4 6 359 3
4.現次dump,取A值的資訊很少
tab 0, row 0, @0x17c0
tl: 9 fb: --H----- lb: 0x2 cc: 0
nrid: 0x01800163.0
從上面dump資訊顯示A所在的位置還在6號檔案的359號塊,row 0(第一行),說明rowid不變,但A值在359塊中沒有了,多出一個 nrid: 0x01800163.0,這個應該是行遷移的地址吧
對這個值換算一下:0000 0001 10 = 6號檔案,0x163=355號塊 ,那麼A值具體應該在這個塊中。。。
再dump看一下是否有4000個A值
data_block_dump,data header at 0x2ab2112dea7c
===============
tsiz: 0x1f80
hsiz: 0x14
pbl: 0x2ab2112dea7c
76543210
flag=--------
ntab=1
nrow=1
frre=-1
fsbo=0x14
fseo=0xfd2
avsp=0xfbe
tosp=0xfbe
0xe:pti[0] nrow=1 offs=0
0x12:pri[0] offs=0xfd2
block_row_dump:
tab 0, row 0, @0xfd2
tl: 4014 fb: ----FL-- lb: 0x1 cc: 2
hrid: 0x01800167.0
col 0: [ 1] 31
col 1: [4000]
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41 41
end_of_block_dump
End dump data blocks tsn: 7 file#: 6 minblk 355 maxblk 355
hrid: 0x01800167.0
這個是上個塊的地址換算成6號檔案的359號塊,就是rowid顯示的這個塊,不變
從以上的dump中看出A值就在355號新塊中。。。
SQL> select dump('A',16) from dual;
DUMP('A',16)
----------------
Typ=96 Len=1: 41
從上面的幾個實驗可以看出,不管值變多長,我們在表中查的 rowid一直不變。。。。
SQL> select id,dbms_rowid.rowid_relative_fno(rowid),dbms_rowid.rowid_block_number(rowid),dbms_rowid.rowid_row_number(rowid) from t2;
ID DBMS_ROWID.ROWID_RELATIVE_FNO(ROWID) DBMS_ROWID.ROWID_BLOCK_NUMBER(ROWID) DBMS_ROWID.ROWID_ROW_NUMBER(ROWID)
---------- ------------------------------------ ------------------------------------ ----------------------------------
1 6 359 0
2 6 359 1
3 6 359 2
4 6 359 3
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/26442936/viewspace-753546/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- DATA BLOCK內部結構BloC
- DATA BLOCK內部結構圖BloC
- 原創:oracle data block 內部結構分析OracleBloC
- Oracle Data block 的物理結構OracleBloC
- RMAN備份效率之-oracle block internal(block 內部結構分解)OracleBloC
- data guard的結構常識(轉載)
- Oracle Data block 的物理結構-體系架構OracleBloC架構
- oracle資料檔案內部BLOCK結構詳解OracleBloC
- 資料塊內部結構dump解析
- PostgreSQL DBA(17) - XLOG Record data內部結構SQL
- CLUSTER內部結構的總結(1)
- CLUSTER內部結構的總結(2)
- CLUSTER內部結構的總結(3)
- CLUSTER內部結構的總結(4)
- 淺析Block的內部結構 , 及分析其是如何利用 NSInvocation 進行呼叫BloC
- date型別的內部結構型別
- B樹索引的內部結構索引
- 區塊鏈(Block Chain)結構解析區塊鏈BloCAI
- (轉)怎樣才能dump資料庫的內部結構?資料庫
- iOS 揭露Block的內部實現原理iOSBloC
- [轉載]ORA-01578: ORACLE data block corruptedOracleBloC
- LoadRunner內部結構
- 索引內部結構探索索引
- undo 事物內部結構
- 探索Kafka消費者的內部結構Kafka
- Redis資料結構的內部編碼Redis資料結構
- dump Oracle資料庫的內部結構Oracle資料庫
- Cassandra的內部資料儲存結構
- 文章的基本結構
- Redis 內部資料結構Redis資料結構
- 【REDO】Oracle redo內部結構Oracle Redo
- MySQL-InnoDB內部結構MySql
- zt_data block資料塊之物理結構初識BloC
- Kafak探究之路- 內部結構小結
- Export data from a data blockExportBloC
- Redis 字串 內部資料結構Redis字串資料結構
- 【原創】MySQLProxy-內部結構MySql
- zt_undo 事物內部結構