WEB开发网
开发学院数据库Oracle sqlplus的oci prefetch特性 阅读

sqlplus的oci prefetch特性

 2008-12-17 13:06:27 来源:WEB开发网   
核心提示:Hi TOM,I traced some sqls with " full table scan ",and it always returns 1 row (r=1)during first fetch .Is this because of "cursor prefetch"

Hi TOM,

I traced some sqls with " full table scan ",and it always returns 1 row (r=1)

during first fetch .

Is this because of "cursor prefetch" or else? Hope your advice.

For example,full table scan dual

=====================

PARSING IN CURSOR #1 len=18 dep=0 uid=62 oct=3 lid=62 tim=106633135131
hv=4035109885 ad='65fc41d8'
select * from dual
END OF STMT
PARSE #1:c=0,e=5796,p=0,cr=0,cu=0,mis=1,r=0,dep=0,og=4,tim=106633135123
EXEC #1:c=0,e=44,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=4,tim=106633140740
WAIT #1: nam='SQL*Net message to client' ela= 6 p1=1111838976 p2=1 p3=0
FETCH #1:c=0,e=108,p=0,cr=3,cu=0,mis=0,r=1,dep=0,og=4,tim=106633143298
WAIT #1: nam='SQL*Net message from client' ela= 8755 p1=1111838976 p2=1 p3=0
FETCH #1:c=0,e=3,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=0,tim=106633154841
WAIT #1: nam='SQL*Net message to client' ela= 5 p1=1111838976 p2=1 p3=0
WAIT #1: nam='SQL*Net message from client' ela= 8055707 p1=1111838976 p2=1 p3=0

=====================

For example,full table scan table T

=====================

PARSING IN CURSOR #1 len=31 dep=0 uid=62 oct=3 lid=62 tim=106641556744
hv=1251189969 ad='65fb71a8'
select * from t where rownum<25
END OF STMT
PARSE #1:c=78125,e=304217,p=13,cr=76,cu=0,mis=1,r=0,dep=0,og=4,tim=106641556737
EXEC #1:c=0,e=32,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=4,tim=106641556863
WAIT #1: nam='SQL*Net message to client' ela= 4 p1=1111838976 p2=1 p3=0
WAIT #1: nam='db file sequential read' ela= 20586 p1=9 p2=15459 p3=1
WAIT #1: nam='db file scattered read' ela= 675 p1=9 p2=15460 p3=5
FETCH #1:c=0,e=21702,p=6,cr=7,cu=0,mis=0,r=1,dep=0,og=4,tim=106641578624
WAIT #1: nam='SQL*Net message from client' ela= 463 p1=1111838976 p2=1 p3=0
WAIT #1: nam='SQL*Net message to client' ela= 2 p1=1111838976 p2=1 p3=0
FETCH #1:c=0,e=71,p=0,cr=1,cu=0,mis=0,r=15,dep=0,og=4,tim=106641579287
WAIT #1: nam='SQL*Net message from client' ela= 358220 p1=1111838976 p2=1 p3=0
WAIT #1: nam='SQL*Net message to client' ela= 3 p1=1111838976 p2=1 p3=0
FETCH #1:c=0,e=102,p=0,cr=1,cu=0,mis=0,r=8,dep=0,og=4,tim=106641937758
WAIT #1: nam='SQL*Net message from client' ela= 4991127 p1=1111838976 p2=1 p3=0
STAT #1 id=1 cnt=24 pid=0 pos=1 obj=0 op='COUNT STOPKEY '

1 2  下一页

Tags:sqlplus oci prefetch

编辑录入:爽爽 [复制链接] [打 印]
赞助商链接