https://github.com/karlarao/scripts/blob/master/performance/ash_elap2.sql
@ash_elap2
GV$ACTIVE_SESSION_HISTORY - ash_elap by exec (recent)
~~~~~~~~~~~~~~~~~~~~~~~~~
Enter value for run_time_sec: 1
SQL_ID SQL_EXEC_ID SQL_PLAN_HASH_VALUE SQL_EXEC_START RUN_TIME_TIMESTAMP RUN_TIME_SEC
------------- ----------- ------------------- ------------------------------ ------------------------------ ------------
0qtq6j4k6nk9p 117440512 1124280406 25-SEP-18 11.44.40.000000 AM +000000000 00:00:00.488 .488
22vzar2nd6nay 100663297 1124280406 25-SEP-18 11.44.40.000000 AM +000000000 00:00:00.367 .367
74pzc7sz7av3a 105220059 285568261 25-SEP-18 11.44.40.000000 AM +000000000 00:00:00.367 .367
bgt54a5yg0gfd 117490970 1746889690 25-SEP-18 11.44.40.000000 AM +000000000 00:00:00.488 .488
74pzc7sz7av3a 105220184 285568261 25-SEP-18 11.44.41.000000 AM +000000000 00:00:00.367 .367
74pzc7sz7av3a 105220306 285568261 25-SEP-18 11.44.42.000000 AM +000000000 00:00:00.367 .367
74pzc7sz7av3a 105220436 285568261 25-SEP-18 11.44.43.000000 AM +000000000 00:00:00.367 .367
74pzc7sz7av3a 105220573 285568261 25-SEP-18 11.44.44.000000 AM +000000000 00:00:00.417 .417
74pzc7sz7av3a 105220701 285568261 25-SEP-18 11.44.45.000000 AM +000000000 00:00:00.417 .417
74pzc7sz7av3a 105220824 285568261 25-SEP-18 11.44.46.000000 AM +000000000 00:00:00.417 .417
74pzc7sz7av3a 105220949 285568261 25-SEP-18 11.44.47.000000 AM +000000000 00:00:00.417 .417
ddwfu841v1fjf 100690544 2611103697 25-SEP-18 11.44.47.000000 AM +000000000 00:00:00.417 .417
12 rows selected.
GV$ACTIVE_SESSION_HISTORY - ash_elap exec avg min max
~~~~~~~~~~~~~~~~~~~~~~~~~
Enter value for sql_id: 74pzc7sz7av3a
SQL_PLAN_HASH_VALUE COUNT(*) AVG MIN MAX
------------------- ---------- ---------- ---------- ----------
285568261 18465 1.04 .01 2.01
18465 1.04 .01 2.01
2 rows selected.
https://github.com/karlarao/scripts/blob/master/performance/ash_elap_hist.sql
@ash_elap_hist
DBA_HIST_ACTIVE_SESS_HISTORY - ash_elap by exec (recent)
~~~~~~~~~~~~~~~~~~~~~~~~~
Enter value for run_time_sec: 1
SQL_ID SQL_EXEC_ID SQL_PLAN_HASH_VALUE SQL_EXEC_START RUN_TIME_TIMESTAMP RUN_TIME_SEC
------------- ----------- ------------------- ------------------------------ ------------------------------ ------------
5utgpvzx65hm1 100663296 1906274682 25-SEP-18 11.12.59.000000 AM +000000000 00:00:00.956 .956
74pzc7sz7av3a 105051249 285568261 25-SEP-18 11.13.02.000000 AM +000000000 00:00:00.746 .746
c2gggvvzhasjq 117563103 3740535514 25-SEP-18 11.13.09.000000 AM +000000000 00:00:00.956 .956
3qqz0wv4fcgnp 134217728 1906274682 25-SEP-18 11.13.09.000000 AM +000000000 00:00:00.956 .956
6cy406qas6w1n 117440512 3353309817 25-SEP-18 11.13.09.000000 AM +000000000 00:00:00.956 .956
74pzc7sz7av3a 105052315 285568261 25-SEP-18 11.13.12.000000 AM +000000000 00:00:00.756 .756
cqwfdp2kgp1y6 101236257 2482309837 25-SEP-18 11.13.12.000000 AM +000000000 00:00:00.756 .756
16c06qv3xpma7 100663296 2605956479 25-SEP-18 11.13.12.000000 AM +000000000 00:00:00.756 .756
47scqprr7nszj 117440534 2913405107 25-SEP-18 11.13.19.000000 AM +000000000 00:00:00.282 .282
7hxua2wncw5d0 117440534 2301485473 25-SEP-18 11.13.22.000000 AM +000000000 00:00:00.766 .766
74pzc7sz7av3a 105053530 285568261 25-SEP-18 11.13.22.000000 AM +000000000 00:00:00.766 .766
cvs1v2u20v17s 100669138 1199171944 25-SEP-18 11.13.22.000000 AM +000000000 00:00:00.766 .766
dywrd4mcxzz6r 117440682 2476845023 25-SEP-18 11.13.25.000000 AM +000000000 00:00:00.688 .688
74pzc7sz7av3a 105054683 285568261 25-SEP-18 11.13.32.000000 AM +000000000 00:00:00.786 .786
74pzc7sz7av3a 105055565 285568261 25-SEP-18 11.13.42.000000 AM +000000000 00:00:00.796 .796
6hnhqahphpk8n 101049947 486334127 25-SEP-18 11.13.42.000000 AM +000000000 00:00:00.796 .796
2xjr13r2ps0ps 117440535 2913405107 25-SEP-18 11.13.45.000000 AM +000000000 00:00:00.768 .768
4kvpgj50urguq 117440535 784618092 25-SEP-18 11.13.49.000000 AM +000000000 00:00:00.325 .325
74pzc7sz7av3a 105058008 285568261 25-SEP-18 11.14.02.000000 AM +000000000 00:00:00.858 .858
74pzc7sz7av3a 105058880 285568261 25-SEP-18 11.14.12.000000 AM +000000000 00:00:00.868 .868
0j8r1r5k20q8v 134217728 3888080663 25-SEP-18 11.14.15.000000 AM +000000000 00:00:00.808 .808
74pzc7sz7av3a 105059780 285568261 25-SEP-18 11.14.22.000000 AM +000000000 00:00:00.888 .888
74pzc7sz7av3a 105060459 285568261 25-SEP-18 11.14.32.000000 AM +000000000 00:00:00.898 .898
633r6yjw2810x 83980510 524338161 25-SEP-18 11.14.35.000000 AM +000000000 00:00:00.828 .828
0pfsgspvccttx 100663296 1906274682 25-SEP-18 11.14.35.000000 AM +000000000 00:00:00.828 .828
74pzc7sz7av3a 105061768 285568261 25-SEP-18 11.14.42.000000 AM +000000000 00:00:00.908 .908
9cqctunapqcvg 100663296 1906274682 25-SEP-18 11.14.42.000000 AM +000000000 00:00:00.908 .908
74pzc7sz7av3a 105062677 285568261 25-SEP-18 11.14.52.000000 AM +000000000 00:00:00.958 .958
74pzc7sz7av3a 105063877 285568261 25-SEP-18 11.15.02.000000 AM +000000000 00:00:00.978 .978
9fj9h63mww23z 83909531 1094854453 25-SEP-18 11.15.05.000000 AM +000000000 00:00:00.903 .903
74pzc7sz7av3a 105064861 285568261 25-SEP-18 11.15.12.000000 AM +000000000 00:00:00.988 .988
74pzc7sz7av3a 105066108 285568261 25-SEP-18 11.15.23.000000 AM +000000000 00:00:00.558 .558
39xgr8xdkrqkx 83984787 824599293 25-SEP-18 11.15.25.000000 AM +000000000 00:00:00.933 .933
74pzc7sz7av3a 105067480 285568261 25-SEP-18 11.15.33.000000 AM +000000000 00:00:00.568 .568
74pzc7sz7av3a 105068158 285568261 25-SEP-18 11.15.43.000000 AM +000000000 00:00:00.568 .568
74pzc7sz7av3a 105069008 285568261 25-SEP-18 11.15.53.000000 AM +000000000 00:00:00.613 .613
74pzc7sz7av3a 105069908 285568261 25-SEP-18 11.16.03.000000 AM +000000000 00:00:00.633 .633
4g3ra1httrcgn 83886080 2605956479 25-SEP-18 11.16.06.000000 AM +000000000 00:00:00.423 .423
74pzc7sz7av3a 105070804 285568261 25-SEP-18 11.16.13.000000 AM +000000000 00:00:00.643 .643
74pzc7sz7av3a 105071727 285568261 25-SEP-18 11.16.23.000000 AM +000000000 00:00:00.653 .653
djq13hc2y97zz 100752772 2160510587 25-SEP-18 11.16.33.000000 AM +000000000 00:00:00.673 .673
74pzc7sz7av3a 105072742 285568261 25-SEP-18 11.16.33.000000 AM +000000000 00:00:00.673 .673
74pzc7sz7av3a 105073806 285568261 25-SEP-18 11.16.43.000000 AM +000000000 00:00:00.683 .683
dkvh5g3k1p91s 117440536 2913405107 25-SEP-18 11.16.49.000000 AM +000000000 00:00:00.481 .481
74pzc7sz7av3a 105074482 285568261 25-SEP-18 11.16.53.000000 AM +000000000 00:00:00.733 .733
4kvpgj50urguq 117440536 784618092 25-SEP-18 11.16.53.000000 AM +000000000 00:00:00.733 .733
5v5vpna0y7fs9 87674385 2136748371 25-SEP-18 11.16.56.000000 AM +000000000 00:00:00.520 .52
1x3arz3kk3hmt 83887555 1900108107 25-SEP-18 11.16.56.000000 AM +000000000 00:00:00.520 .52
74pzc7sz7av3a 105075457 285568261 25-SEP-18 11.17.03.000000 AM +000000000 00:00:00.753 .753
7vtkg0hcrmgbu 84903359 2508161379 25-SEP-18 11.17.06.000000 AM +000000000 00:00:00.530 .53
dmvqnvhmsr2h7 117440537 2301485473 25-SEP-18 11.17.13.000000 AM +000000000 00:00:00.753 .753
74pzc7sz7av3a 105076526 285568261 25-SEP-18 11.17.13.000000 AM +000000000 00:00:00.753 .753
fkd52b3c6f0b2 83886080 3221867554 25-SEP-18 11.17.16.000000 AM +000000000 00:00:00.530 .53
atdsgpsx73a2h 117440537 2913405107 25-SEP-18 11.17.20.000000 AM +000000000 00:00:00.434 .434
74pzc7sz7av3a 105077585 285568261 25-SEP-18 11.17.23.000000 AM +000000000 00:00:00.763 .763
74pzc7sz7av3a 105078569 285568261 25-SEP-18 11.17.33.000000 AM +000000000 00:00:00.773 .773
7kkz2fzv5g7z1 100752773 4061398141 25-SEP-18 11.17.33.000000 AM +000000000 00:00:00.773 .773
djq13hc2y97zz 117531884 2160510587 25-SEP-18 11.17.40.000000 AM +000000000 00:00:00.468 .468
fxc4b1c3rk65j 117440538 784618092 25-SEP-18 11.17.40.000000 AM +000000000 00:00:00.468 .468
74pzc7sz7av3a 105079634 285568261 25-SEP-18 11.17.43.000000 AM +000000000 00:00:00.773 .773
6g2xp2qh063r6 117440538 784618092 25-SEP-18 11.17.43.000000 AM +000000000 00:00:00.773 .773
5y1gjhra8hj8f 83886080 3539988539 25-SEP-18 11.17.46.000000 AM +000000000 00:00:00.590 .59
df26ktwq2sx6h 83889581 3295683921 25-SEP-18 11.17.46.000000 AM +000000000 00:00:00.590 .59
dzs3rm0w0bgnv 115836193 435344142 25-SEP-18 11.17.53.000000 AM +000000000 00:00:00.812 .812
74pzc7sz7av3a 105080595 285568261 25-SEP-18 11.17.53.000000 AM +000000000 00:00:00.812 .812
74pzc7sz7av3a 105081651 285568261 25-SEP-18 11.18.03.000000 AM +000000000 00:00:00.822 .822
74pzc7sz7av3a 105082322 285568261 25-SEP-18 11.18.13.000000 AM +000000000 00:00:00.822 .822
b0gx2k2r95czt 134242460 2897135679 25-SEP-18 11.18.19.000000 AM +000000000 00:00:00.581 .581
dywrd4mcxzz6r 117440709 2476845023 25-SEP-18 11.18.23.000000 AM +000000000 00:00:00.832 .832
74pzc7sz7av3a 105083386 285568261 25-SEP-18 11.18.23.000000 AM +000000000 00:00:00.832 .832
74pzc7sz7av3a 105084460 285568261 25-SEP-18 11.18.33.000000 AM +000000000 00:00:00.832 .832
7vtkg0hcrmgbu 84903493 2508161379 25-SEP-18 11.18.36.000000 AM +000000000 00:00:00.630 .63
9fj9h63mww23z 117531887 1094854453 25-SEP-18 11.18.40.000000 AM +000000000 00:00:00.608 .608
cqwfdp2kgp1y6 101237661 2482309837 25-SEP-18 11.18.43.000000 AM +000000000 00:00:00.842 .842
74pzc7sz7av3a 105085626 285568261 25-SEP-18 11.18.43.000000 AM +000000000 00:00:00.842 .842
74pzc7sz7av3a 105086378 285568261 25-SEP-18 11.18.53.000000 AM +000000000 00:00:00.882 .882
anmx8kw97zmut 100663296 1906274682 25-SEP-18 11.18.53.000000 AM +000000000 00:00:00.882 .882
74pzc7sz7av3a 105087016 285568261 25-SEP-18 11.19.03.000000 AM +000000000 00:00:00.882 .882
39xgr8xdkrqkx 83984945 824599293 25-SEP-18 11.19.06.000000 AM +000000000 00:00:00.680 .68
74pzc7sz7av3a 105087903 285568261 25-SEP-18 11.19.13.000000 AM +000000000 00:00:00.892 .892
28y7zpmuh3g0q 83886670 0 25-SEP-18 11.19.16.000000 AM +000000000 00:00:00.680 .68
74pzc7sz7av3a 105088782 285568261 25-SEP-18 11.19.23.000000 AM +000000000 00:00:00.902 .902
bf7gjxp8bv90m 83886676 1761485131 25-SEP-18 11.19.26.000000 AM +000000000 00:00:00.690 .69
5s0zcy0jf2g1b 83886080 2163920586 25-SEP-18 11.19.26.000000 AM +000000000 00:00:00.690 .69
74pzc7sz7av3a 105089765 285568261 25-SEP-18 11.19.33.000000 AM +000000000 00:00:00.902 .902
093kf50gfjnj0 117444342 2521440651 25-SEP-18 11.19.40.000000 AM +000000000 00:00:00.739 .739
74pzc7sz7av3a 105090590 285568261 25-SEP-18 11.19.43.000000 AM +000000000 00:00:00.912 .912
4kfp681g8d8r3 83886080 2605956479 25-SEP-18 11.19.46.000000 AM +000000000 00:00:00.730 .73
bhah6b7jtxq89 134218284 4006875738 25-SEP-18 11.19.49.000000 AM +000000000 00:00:00.652 .652
74pzc7sz7av3a 105091573 285568261 25-SEP-18 11.19.53.000000 AM +000000000 00:00:00.947 .947
74pzc7sz7av3a 105092654 285568261 25-SEP-18 11.20.03.000000 AM +000000000 00:00:00.957 .957
3xvwzas9whdp7 83886965 1876882583 25-SEP-18 11.20.09.000000 AM +000000000 00:00:00.662 .662
89sty5w9fb3x5 117441090 4001706426 25-SEP-18 11.20.10.000000 AM +000000000 00:00:00.829 .829
74pzc7sz7av3a 105093661 285568261 25-SEP-18 11.20.13.000000 AM +000000000 00:00:00.957 .957
9bsxh5s883mbw 83886658 870464312 25-SEP-18 11.20.16.000000 AM +000000000 00:00:00.740 .74
b1npvhssr8n0m 117492338 1823423974 25-SEP-18 11.20.20.000000 AM +000000000 00:00:00.849 .849
7z0a59ww2xgks 83900144 463974827 25-SEP-18 11.20.26.000000 AM +000000000 00:00:00.750 .75
fvv08bb0gy02p 83888085 560433498 25-SEP-18 11.20.36.000000 AM +000000000 00:00:00.750 .75
5rqw910mvrvjc 117440540 784618092 25-SEP-18 11.21.09.000000 AM +000000000 00:00:00.722 .722
6g2xp2qh063r6 117440540 784618092 25-SEP-18 11.21.10.000000 AM +000000000 00:00:00.949 .949
74pzc7sz7av3a 105099289 285568261 25-SEP-18 11.21.14.000000 AM +000000000 00:00:00.377 .377
74pzc7sz7av3a 105100423 285568261 25-SEP-18 11.21.24.000000 AM +000000000 00:00:00.387 .387
4p70grqk8csrj 117440541 2913405107 25-SEP-18 11.21.30.000000 AM +000000000 00:00:00.979 .979
74pzc7sz7av3a 105101252 285568261 25-SEP-18 11.21.34.000000 AM +000000000 00:00:00.407 .407
7pntpyytmk8um 117440541 2913405107 25-SEP-18 11.21.39.000000 AM +000000000 00:00:00.764 .764
74pzc7sz7av3a 105102178 285568261 25-SEP-18 11.21.44.000000 AM +000000000 00:00:00.467 .467
74pzc7sz7av3a 105103120 285568261 25-SEP-18 11.21.54.000000 AM +000000000 00:00:00.477 .477
1mg5a4zvujbqn 134224551 1103282287 25-SEP-18 11.21.59.000000 AM +000000000 00:00:00.774 .774
74pzc7sz7av3a 105104190 285568261 25-SEP-18 11.22.04.000000 AM +000000000 00:00:00.487 .487
74pzc7sz7av3a 105105344 285568261 25-SEP-18 11.22.14.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105106268 285568261 25-SEP-18 11.22.24.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105107410 285568261 25-SEP-18 11.22.34.000000 AM +000000000 00:00:00.517 .517
3dvcu27p1j3d1 50331648 443884347 25-SEP-18 11.22.34.000000 AM +000000000 00:00:00.517 .517
74pzc7sz7av3a 105108589 285568261 25-SEP-18 11.22.44.000000 AM +000000000 00:00:00.557 .557
c2gggvvzhasjq 100668029 2170478453 25-SEP-18 11.22.44.000000 AM +000000000 00:00:00.557 .557
74pzc7sz7av3a 105109622 285568261 25-SEP-18 11.22.54.000000 AM +000000000 00:00:00.557 .557
bhah6b7jtxq89 134218290 4006875738 25-SEP-18 11.22.59.000000 AM +000000000 00:00:00.824 .824
74pzc7sz7av3a 105110757 285568261 25-SEP-18 11.23.04.000000 AM +000000000 00:00:00.557 .557
39xgr8xdkrqkx 100850809 824599293 25-SEP-18 11.23.04.000000 AM +000000000 00:00:00.557 .557
74pzc7sz7av3a 105112035 285568261 25-SEP-18 11.23.14.000000 AM +000000000 00:00:00.567 .567
74pzc7sz7av3a 105113040 285568261 25-SEP-18 11.23.24.000000 AM +000000000 00:00:00.567 .567
74pzc7sz7av3a 105114179 285568261 25-SEP-18 11.23.34.000000 AM +000000000 00:00:00.577 .577
74pzc7sz7av3a 105115336 285568261 25-SEP-18 11.23.44.000000 AM +000000000 00:00:00.617 .617
8czh15cga3vxv 100665431 0 25-SEP-18 11.23.44.000000 AM +000000000 00:00:00.617 .617
74pzc7sz7av3a 105116271 285568261 25-SEP-18 11.23.54.000000 AM +000000000 00:00:00.615 .615
5v5vpna0y7fs9 137833603 2136748371 25-SEP-18 11.23.59.000000 AM +000000000 00:00:00.891 .891
dkvh5g3k1p91s 117440542 2913405107 25-SEP-18 11.23.59.000000 AM +000000000 00:00:00.891 .891
74pzc7sz7av3a 105117484 285568261 25-SEP-18 11.24.04.000000 AM +000000000 00:00:00.625 .625
74pzc7sz7av3a 105118376 285568261 25-SEP-18 11.24.14.000000 AM +000000000 00:00:00.625 .625
75arzw3b4gnq6 117440543 2913405107 25-SEP-18 11.24.19.000000 AM +000000000 00:00:00.961 .961
74pzc7sz7av3a 105119344 285568261 25-SEP-18 11.24.24.000000 AM +000000000 00:00:00.625 .625
74pzc7sz7av3a 105120293 285568261 25-SEP-18 11.24.34.000000 AM +000000000 00:00:00.635 .635
0f1m37wgds0yh 117440544 784618092 25-SEP-18 11.24.34.000000 AM +000000000 00:00:00.635 .635
7hxua2wncw5d0 117440544 2301485473 25-SEP-18 11.24.39.000000 AM +000000000 00:00:00.981 .981
74pzc7sz7av3a 105121294 285568261 25-SEP-18 11.24.44.000000 AM +000000000 00:00:00.685 .685
74pzc7sz7av3a 105122126 285568261 25-SEP-18 11.24.54.000000 AM +000000000 00:00:00.685 .685
74pzc7sz7av3a 105122916 285568261 25-SEP-18 11.25.04.000000 AM +000000000 00:00:00.695 .695
74pzc7sz7av3a 105123655 285568261 25-SEP-18 11.25.14.000000 AM +000000000 00:00:00.695 .695
fxc4b1c3rk65j 117440546 784618092 25-SEP-18 11.27.41.000000 AM +000000000 00:00:00.667 .667
4kvpgj50urguq 117440547 784618092 25-SEP-18 11.28.11.000000 AM +000000000 00:00:00.747 .747
5v5vpna0y7fs9 104373418 2136748371 25-SEP-18 11.28.35.000000 AM +000000000 00:00:00.590 .59
74pzc7sz7av3a 105142386 285568261 25-SEP-18 11.28.35.000000 AM +000000000 00:00:00.590 .59
74pzc7sz7av3a 105143450 285568261 25-SEP-18 11.28.45.000000 AM +000000000 00:00:00.650 .65
74pzc7sz7av3a 105144473 285568261 25-SEP-18 11.28.55.000000 AM +000000000 00:00:00.660 .66
74pzc7sz7av3a 105145514 285568261 25-SEP-18 11.29.05.000000 AM +000000000 00:00:00.680 .68
74pzc7sz7av3a 105146200 285568261 25-SEP-18 11.29.15.000000 AM +000000000 00:00:00.690 .69
74pzc7sz7av3a 105146927 285568261 25-SEP-18 11.29.25.000000 AM +000000000 00:00:00.700 .7
74pzc7sz7av3a 105147653 285568261 25-SEP-18 11.29.35.000000 AM +000000000 00:00:00.720 .72
74pzc7sz7av3a 105148518 285568261 25-SEP-18 11.29.45.000000 AM +000000000 00:00:00.770 .77
74pzc7sz7av3a 105149329 285568261 25-SEP-18 11.29.55.000000 AM +000000000 00:00:00.788 .788
74pzc7sz7av3a 105150020 285568261 25-SEP-18 11.30.05.000000 AM +000000000 00:00:00.798 .798
74pzc7sz7av3a 105150994 285568261 25-SEP-18 11.30.15.000000 AM +000000000 00:00:00.818 .818
6hnhqahphpk8n 134253354 486334127 25-SEP-18 11.36.20.000000 AM +000000000 00:00:00.792 .792
1mg5a4zvujbqn 134224622 1103282287 25-SEP-18 11.37.20.000000 AM +000000000 00:00:00.842 .842
84u57ud52w2ub 134220712 205846548 25-SEP-18 11.37.50.000000 AM +000000000 00:00:00.852 .852
djq13hc2y97zz 134310263 2160510587 25-SEP-18 11.38.10.000000 AM +000000000 00:00:00.862 .862
bhah6b7jtxq89 134218321 4006875738 25-SEP-18 11.38.30.000000 AM +000000000 00:00:00.902 .902
39xgr8xdkrqkx 134384406 824599293 25-SEP-18 11.38.40.000000 AM +000000000 00:00:00.902 .902
7kkz2fzv5g7z1 134310264 4061398141 25-SEP-18 11.39.10.000000 AM +000000000 00:00:00.922 .922
63kf3an2j0pkc 117461900 2522716884 25-SEP-18 11.39.12.000000 AM +000000000 00:00:00.987 .987
d61hkb9udm6qp 135518962 3731279724 25-SEP-18 11.39.50.000000 AM +000000000 00:00:00.962 .962
3g00jhr4m7jad 134244758 3467682888 25-SEP-18 11.40.00.000000 AM +000000000 00:00:00.972 .972
43mhqvds58xm3 100663296 1124280406 25-SEP-18 11.41.27.000000 AM +000000000 00:00:00.989 .989
dywrd4mcxzz6r 117440853 2476845023 25-SEP-18 11.41.37.000000 AM +000000000 00:00:00.999 .999
74pzc7sz7av3a 105202382 285568261 25-SEP-18 11.41.37.000000 AM +000000000 00:00:00.999 .999
165 rows selected.
DBA_HIST_ACTIVE_SESS_HISTORY - ash_elap exec avg min max
~~~~~~~~~~~~~~~~~~~~~~~~~
Enter value for sql_id: 74pzc7sz7av3a
SQL_PLAN_HASH_VALUE COUNT(*) AVG MIN MAX
------------------- ---------- ---------- ---------- ----------
285568261 24516 1.02 .01 2.08
3889266742 1 .96 .96 .96
24517 1.02 .01 2.08
3 rows selected.
https://github.com/karlarao/scripts/blob/master/performance/planx.sql
@planx Y 74pzc7sz7av3a
./planxparse.sh planx_74pzc7sz7av3a_20180925_112228.txt
avg_exec: 1.95151e+06
avg_elap: 22383.6
avg_cpu: 20991.1
avg_elap/exec: 0.0114699
avg_cp/execu: 0.0107564
cat krlavg.txt | head -n10
EXEC ELAP_SEC CPU_SEC
4304370 48841.810 47814.818
4003757 45318.622 44317.854
3688361 41776.145 40792.563
3369061 38270.149 37302.683
3047451 34750.396 33806.518
2896738 37625.441 35506.783
2885443 32983.788 32051.714
2886660 32449.433 31676.863
2839114 26729.537 26585.930
2503828 33034.167 30977.112
ON THE SAME PLANX FILE - THE ASH SECTION
GV$ACTIVE_SESSION_HISTORY - ash_elap by exec (recent 20)
~~~~~~~~~~~~~~~~~~~~~~~~~
74pzc7sz7av3a 105104993 285568261 25-SEP-18 11.22.11.000000 AM +000000000 00:00:00.497 .497
74pzc7sz7av3a 105105121 285568261 25-SEP-18 11.22.12.000000 AM +000000000 00:00:00.497 .497
74pzc7sz7av3a 105105242 285568261 25-SEP-18 11.22.13.000000 AM +000000000 00:00:00.497 .497
74pzc7sz7av3a 105105344 285568261 25-SEP-18 11.22.14.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105105445 285568261 25-SEP-18 11.22.15.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105105536 285568261 25-SEP-18 11.22.16.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105105631 285568261 25-SEP-18 11.22.17.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105105720 285568261 25-SEP-18 11.22.18.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105105801 285568261 25-SEP-18 11.22.19.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105105893 285568261 25-SEP-18 11.22.20.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105105983 285568261 25-SEP-18 11.22.21.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105106077 285568261 25-SEP-18 11.22.22.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105106173 285568261 25-SEP-18 11.22.23.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105106268 285568261 25-SEP-18 11.22.24.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105106378 285568261 25-SEP-18 11.22.25.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105106494 285568261 25-SEP-18 11.22.26.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105106602 285568261 25-SEP-18 11.22.27.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105106703 285568261 25-SEP-18 11.22.28.000000 AM +000000000 00:00:00.507 .507
74pzc7sz7av3a 105106817 285568261 25-SEP-18 11.22.29.000000 AM +000000000 00:00:00.517 .517
74pzc7sz7av3a 105106894 285568261 25-SEP-18 11.22.30.000000 AM +000000000 00:00:00.517 .517
GV$ACTIVE_SESSION_HISTORY - ash_elap exec avg min max
~~~~~~~~~~~~~~~~~~~~~~~~~
285568261 17142 1.03 .01 2.01
17142 1.03 .01 2.01
GV$ACTIVE_SESSION_HISTORY
~~~~~~~~~~~~~~~~~~~~~~~~~
SAMPLES PERCENT TIMED_EVENT
---------------- -------- ----------------------------------------------------------------------
17,166 100.0 ON CPU
GV$ACTIVE_SESSION_HISTORY - by inst_id
~~~~~~~~~~~~~~~~~~~~~~~~~
SAMPLES PERCENT INST_ID TIMED_EVENT
---------------- -------- ---------- ----------------------------------------------------------------------
17,166 100.0 6 ON CPU
GV$ACTIVE_SESSION_HISTORY
~~~~~~~~~~~~~~~~~~~~~~~~~
SAMPLES PERCENT PLAN_HASH_VALUE LINE_ID OPERATION TIMED_EVENT
---------------- -------- --------------- -------- -------------------------------------------------- ----------------------------------------------------------------------
17,077 99.5 285568261 2 MAT_VIEW ACCESS STORAGE FULL ON CPU
89 0.5 285568261 0 SELECT STATEMENT ON CPU
GV$ACTIVE_SESSION_HISTORY
~~~~~~~~~~~~~~~~~~~~~~~~~
SAMPLES PERCENT PLAN_HASH_VALUE LINE_ID OPERATION CURRENT_OBJECT TIMED_EVENT
---------------- -------- --------------- -------- -------------------------------------------------- ------------------------------------------------------------ ----------------------------------------------------------------------
17,078 99.5 285568261 2 MAT_VIEW ACCESS STORAGE FULL SERIAL -1 ON CPU
89 0.5 285568261 0 SELECT STATEMENT SERIAL -1 ON CPU
GV$ACTIVE_SESSION_HISTORY - px distribution
~~~~~~~~~~~~~~~~~~~~~~~~~
SQL_EXEC_START SQL_EXEC_ID SQL_PLAN_HASH_VALUE SQL_PLAN_LINE_ID DOP PROGRAM COUNT(*)
------------------------------ ----------- ------------------- ---------------- ---------- ------------------------------------------------------------ ----------
25-SEP-18 11.22.30.000000 AM 105106894 285568261 2 SERIAL QvConnect64.EXE 1
25-SEP-18 11.22.32.000000 AM 105107146 285568261 2 SERIAL QvConnect64.EXE 1
25-SEP-18 11.22.33.000000 AM 105107273 285568261 2 SERIAL QvConnect64.EXE 1
also see https://karlarao.github.io/karlaraowiki/index.html#Elapsed-AvgMinMax