Jaruwan Na Ranong, June 04, 2012 - 12:38 pm UTC
Misses in library cache during parse: 1
Optimizer mode: ALL_ROWS
Parsing user id: 75
Number of plan statistics captured: 1
Rows (1st) Rows (avg) Rows (max) Row Source Operation
---------- ---------- ---------- ---------------------------------------------------
12 12 12 TEMP TABLE TRANSFORMATION (cr=250772 pr=237420 pw=7 time=580766361 us)
0 0 0 LOAD AS SELECT (cr=684 pr=58 pw=2 time=1049509 us)
1704 1704 1704 TABLE ACCESS BY INDEX ROWID W_DAY_D (cr=684 pr=57 pw=0 time=3666225 us cost=0 size=220980 card=1740)
1704 1704 1704 INDEX RANGE SCAN W_DAY_D_M60 (cr=3 pr=3 pw=0 time=33438 us cost=0 size=0 card=1740)(object id 205210)
0 0 0 LOAD AS SELECT (cr=10 pr=10 pw=1 time=118648 us)
42 42 42 PARTITION LIST SINGLE PARTITION: KEY KEY (cr=10 pr=9 pw=0 time=54257 us cost=15 size=1080 card=30)
42 42 42 TABLE ACCESS BY LOCAL INDEX ROWID W_BUSN_LOCATION_D PARTITION: 1 1 (cr=10 pr=9 pw=0 time=54197 us cost=15 size=1080 card=30)
42 42 42 BITMAP CONVERSION TO ROWIDS (cr=8 pr=7 pw=0 time=47395 us)
1 1 1 BITMAP AND (cr=8 pr=7 pw=0 time=47341 us)
2 2 2 BITMAP INDEX SINGLE VALUE W_BUSN_LOC_D_M3 PARTITION: 1 1 (cr=4 pr=3 pw=0 time=24440 us)(object id 141361)
1 1 1 BITMAP OR (cr=4 pr=4 pw=0 time=22836 us)
1 1 1 BITMAP INDEX SINGLE VALUE W_BUSN_LOC_D_M13 PARTITION: 1 1 (cr=2 pr=2 pw=0 time=11448 us)(object id 141376)
1 1 1 BITMAP CONVERSION FROM ROWIDS (cr=2 pr=2 pw=0 time=11348 us)
1 1 1 SORT ORDER BY (cr=2 pr=2 pw=0 time=11332 us)
1 1 1 INDEX RANGE SCAN W_BUSN_LOC_D_P1 PARTITION: 1 1 (cr=2 pr=2 pw=0 time=11230 us cost=2 size=0 card=0)(object id 141296)
0 0 0 LOAD AS SELECT (cr=10 pr=8 pw=4 time=120518 us)
4358 4358 4358 PARTITION LIST SINGLE PARTITION: KEY KEY (cr=10 pr=7 pw=0 time=55915 us cost=5 size=91518 card=4358)
4358 4358 4358 INDEX FAST FULL SCAN W_XACT_TYPE_D_U2 PARTITION: 1 1 (cr=10 pr=7 pw=0 time=54402 us cost=5 size=91518 card=4358)(object id 148481)
12 12 12 SORT GROUP BY (cr=250068 pr=237344 pw=0 time=579475379 us cost=8015 size=5463512 card=29693)
1723214 1723214 1723214 HASH JOIN (cr=250068 pr=237344 pw=0 time=467427194 us cost=7522 size=5463512 card=29693)
4358 4358 4358 TABLE ACCESS FULL SYS_TEMP_0FD9E6F1F_490D08CF (cr=7 pr=4 pw=0 time=2614 us cost=5 size=91518 card=4358)
1723214 1723214 1723214 HASH JOIN (cr=250061 pr=237340 pw=0 time=464782400 us cost=7516 size=4839959 card=29693)
1704 1704 1704 TABLE ACCESS FULL SYS_TEMP_0FD9E6F1D_490D08CF (cr=5 pr=2 pw=0 time=3922 us cost=6 size=203580 card=1740)
1723214 1723214 1723214 HASH JOIN (cr=250056 pr=237338 pw=0 time=462382480 us cost=7510 size=1365878 card=29693)
42 42 42 TABLE ACCESS FULL SYS_TEMP_0FD9E6F1E_490D08CF (cr=4 pr=1 pw=0 time=13235 us cost=3 size=270 card=30)
1723214 1723214 1723214 PARTITION LIST SINGLE PARTITION: KEY KEY (cr=250052 pr=237337 pw=0 time=458150125 us cost=7506 size=1098641 card=29693)
1723214 1723214 1723214 TABLE ACCESS BY LOCAL INDEX ROWID W_SALES_CYCLE_LINE_F PARTITION: 1 1 (cr=250052 pr=237337 pw=0 time=457531613 us cost=7506 size=1098641 car
d=29693)
1723214 1723214 1723214 BITMAP CONVERSION TO ROWIDS (cr=13633 pr=918 pw=0 time=6372139 us)
46 46 46 BITMAP AND (cr=13633 pr=918 pw=0 time=6679579 us)
59 59 59 BITMAP MERGE (cr=355 pr=248 pw=0 time=2042492 us)
23814 23814 23814 BITMAP KEY ITERATION (cr=355 pr=248 pw=0 time=1293967 us)
42 42 42 TABLE ACCESS FULL SYS_TEMP_0FD9E6F1E_490D08CF (cr=2 pr=0 pw=0 time=1090 us cost=3 size=180 card=30)
23814 23814 23814 BITMAP INDEX RANGE SCAN W_SLS_CC_LN_F_F32 PARTITION: 1 1 (cr=353 pr=248 pw=0 time=15029255 us)(object id 122471)
46 46 46 BITMAP MERGE (cr=4010 pr=203 pw=0 time=1215799 us)
526 526 526 BITMAP KEY ITERATION (cr=4010 pr=203 pw=0 time=1366057 us)
1704 1704 1704 TABLE ACCESS FULL SYS_TEMP_0FD9E6F1D_490D08CF (cr=3 pr=0 pw=0 time=3844 us cost=6 size=10440 card=1740)
526 526 526 BITMAP INDEX RANGE SCAN W_SLS_CC_LN_F_F52 PARTITION: 1 1 (cr=4007 pr=203 pw=0 time=443799 us)(object id 122451)
59 59 59 BITMAP MERGE (cr=9188 pr=387 pw=0 time=2702418 us)
40575 40575 40575 BITMAP KEY ITERATION (cr=9188 pr=387 pw=0 time=996154 us)
4358 4358 4358 TABLE ACCESS FULL SYS_TEMP_0FD9E6F1F_490D08CF (cr=5 pr=0 pw=0 time=4181 us cost=5 size=21790 card=4358)
40575 40575 40575 BITMAP INDEX RANGE SCAN W_SLS_CC_LN_F_F47 PARTITION: 1 1 (cr=9183 pr=387 pw=0 time=13576647 us)(object id 122316)
4810 4810 4810 BITMAP INDEX SINGLE VALUE W_SLS_CC_LN_F_M1 PARTITION: 1 1 (cr=80 pr=80 pw=0 time=14835 us)(object id 122311)
June 04, 2012 - 12:56 pm UTC
the answer is the same, you need to make it do less physical IO - I don't know what else I can say honestly.
And this is still not very readable :)
but in any case - one would need a ton of information to "tune" a query - like knowledge of the schema, the question being asked, the data patterns (how the rows are actually physically loaded on disk - in what order) and so on (I don't want all of that, I cannot just tune queries like that)
for "auto tuning" advice, run it through a sql tuning set and see what OEM says.
Jaruwan Na Ranong, June 06, 2012 - 10:59 am UTC
If I can not make less I/O reading, is there possibility that the query can run in multiple threads and still reading index wihout doing full tablescan especially W_SALES_CYCLE_LINE_F partition (AMER).
June 06, 2012 - 11:35 am UTC
no, not really.
Jaruwan Na Ranong, June 06, 2012 - 11:42 am UTC
I have run the SQL tuning advisor from OEM and no recommendation generated. So basically the query perform on its best already based on current configuration of everything. So index scaning can not be run in parallel unless it is fast full scan index?
June 06, 2012 - 1:02 pm UTC
correct, unless they are partitioned.
but even so, if you go parallel, you'll increase the IO wait times for each individual IO since you'll be hitting it even harder than you are now.
why are you afraid of a full scan?
Jaruwan Na Ranong, June 06, 2012 - 2:59 pm UTC
We partition table DWH_GLOBAL.W_SALES_CYCLE_LINE_F on region, currently we use partition "AMER" (where datasource_num_id = 4.0) and the query seem to after 10% of partition. I have tried with full tablescan on DWH_GLOBAL.W_SALES_CYCLE_LINE_F (AMER) and it run longer. And based on the WHERE clause only 2 columns that seem to be candidate for partition (DELETE_FLG and DATASOURCE_NUM_ID), right now DELETE_FLG = 'N' is entire AMER partition.
History of file# or object# for db file sequetial read evet
Pratik Shah, March 08, 2013 - 8:59 am UTC
Hello sir,
Is there any way I can see history of "db file sequential read" event for one session? Basically I want to know that on which object the session spent more time while doing "db file sequetial read". There is a performance issue with of merge statement and I don't have trace enabled for the session. But at runtime, I noticed in v$session.event = 'db file sequential read' and v$session.p1= 'undo tablespace file id'.
Regards,
Pratik Shah
March 11, 2013 - 8:16 am UTC
the ASH repository can give you some glimpse into that, but we do not store anywhere the entire history - not even close, not even a tiny bit close. that would be *huge*
use ASH to see what that statement was mostly waiting on. It'll give you a good picture.
A reader, September 16, 2022 - 4:35 am UTC