Solved

Oracle query on DBA_HIST_ACTIVE_SESS_HISTORY

Posted on 2015-02-16
11
276 Views
Last Modified: 2015-02-17
Hi experts,
I've this output from DBA_HIST_ACTIVE_SESS_HISTORY Oracle view for single SQL_ID (more 10000 rows):
SAMPLE_TIME                                                                 SQL_PLAN_HASH_VALUE                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
--------------------------------------------------------------------------- -------------------                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:13:24,197                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:13:34,207                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:13:44,227                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:13:54,237                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:14:04,247                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:14:14,257                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:14:24,267                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:14:34,277                                                                347981446 
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                
14-FEB-15 05:14:44,297                                                                225587999                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:14:54,307                                                                225587999                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:15:04,317                                                                225587999  
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               
14-FEB-15 05:15:14,327                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:15:24,337                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:15:34,347                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:15:44,371                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:15:54,391                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:16:04,411                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:16:14,421                                                                347981446 
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                
14-FEB-15 05:16:24,431                                                                225587999                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:16:34,441                                                                225587999                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:16:44,451                                                                225587999                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:16:54,451                                                                225587999  
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               
14-FEB-15 05:17:04,461                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:17:14,481                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:17:24,501                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:17:34,511                                                                347981446                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:17:44,545                                                                347981446 
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                
14-FEB-15 05:17:54,555                                                                225587999                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:18:04,565                                                                225587999                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 
14-FEB-15 05:18:14,575                                                                225587999  
--------------------------------------------------------------------------- -------------------
--------------------------------------------------------------------------- -------------------
--------------------------------------------------------------------------- -------------------

Open in new window

SQL_ID having different execution plans an I'd like to check when It change execution plan, i.e. I'd like to have an output like this:

SQL_PLAN_HASH_VALUE     START      					END                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            
-------------------     -------------------      -------------------                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            
347981446               14-FEB-15 05:13:24,197   14-FEB-15 05:14:34,277  
225587999               14-FEB-15 05:14:44,297   14-FEB-15 05:15:04,317
347981446               14-FEB-15 05:15:14,327   14-FEB-15 05:16:14,421
225587999               14-FEB-15 05:16:24,431   14-FEB-15 05:16:54,451
347981446               14-FEB-15 05:17:04,461   14-FEB-15 05:17:44,545
225587999               14-FEB-15 05:17:54,555   14-FEB-15 05:18:14,575

Open in new window


How can I write a query with this result?

Thanks in advance!
0
Comment
Question by:ralph_rea
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 5
11 Comments
 
LVL 35

Accepted Solution

by:
johnsone earned 500 total points
ID: 40612030
It should be something like this:

SELECT sql_plan_hash_value, 
       Min(sample_time) start, 
       Max(sample_time) END 
FROM   dba_hist_active_sess_history 
WHERE  ....
GROUP  BY sql_plan_hash_value 

Open in new window


Just stick your original where clause into the query.
0
 

Author Comment

by:ralph_rea
ID: 40612041
Johnsone,
I had already tried your query, but it returns only a single run group by  sql_plan_hash_value


Have you any idea?
0
 
LVL 35

Expert Comment

by:johnsone
ID: 40612060
Please post the query that returned the original set of data.
0
What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

 
LVL 35

Expert Comment

by:johnsone
ID: 40612122
I trolled through the view to find a SQL_ID that had more than one plan hash and the query worked just fine for me:

SQL> select sql_plan_hash_value, min(sample_time), max(sample_time)
  2  from dba_hist_active_sess_history
  3  where sql_id = '616m6uhpa2usu'
  4  group by sql_plan_hash_value;
SQL_PLAN_HASH_VALUE
-------------------
MIN(SAMPLE_TIME)
---------------------------------------------------------------------------
MAX(SAMPLE_TIME)
---------------------------------------------------------------------------
         2556297882
07-JUN-14 07.29.44.351 AM
07-JUN-14 07.29.44.351 AM

         2542797530
07-JUN-14 07.29.34.341 AM
07-JUN-14 07.29.34.341 AM

Open in new window

0
 

Author Comment

by:ralph_rea
ID: 40612177
Below practice example:

create table DBA_HIST_ACTIVE_SESS_HISTORY2
(SAMPLE_TIME timestamp (3),
SQL_PLAN_HASH_VALUE number);

--run sql file attached

SQL>@ins.sql

In my example:

225587999
1) start:  14/02/2015 5:13:24,197   end:  14/02/2015 5:58:17,630
2) start:  15/02/2015 1:16:41,699  end:  15/02/2015 1:57:14,688


347981446
1) start: 14/02/2015 6:02:27,946   end: 15/02/2015 1:15:01,581

but your query:
SQL>   select sql_plan_hash_value, min(sample_time) min, max(sample_time) max
  2    from dba_hist_active_sess_history2
  3      group by sql_plan_hash_value;

SQL_PLAN_HASH_VALUE         MIN                                          MAX
-------------------                      ------------------------------       ------------------------------
          347981446                  14-FEB-15 06:02:27,946         15-FEB-15 01:15:01,581
          225587999                  14-FEB-15 05:13:24,197         15-FEB-15 01:57:14,688

Open in new window

0
 
LVL 35

Expert Comment

by:johnsone
ID: 40612322
There is no attachment.

Also, where are you getting the end time from?  There is only a one time.
0
 

Author Comment

by:ralph_rea
ID: 40612344
I've problem with attachment. It's pending UPLOADING...
0
 
LVL 35

Expert Comment

by:johnsone
ID: 40612380
Can you post the insert statements here within a code block?

Also, still need to know the breakout of how you are partitioning the start and end times.  Is it by day, or something else?
0
 

Author Comment

by:ralph_rea
ID: 40612437
Ok, look this sql file below:
SET DEFINE OFF;
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:13:24.197','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:13:34.207','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:13:44.227','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:13:54.237','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:14:04.247','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:14:14.257','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:14:24.267','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:14:34.277','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:14:44.297','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:14:54.307','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:15:04.317','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:15:14.327','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:15:24.337','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:15:34.347','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:15:44.371','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:15:54.391','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:16:04.411','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:16:14.421','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:16:24.431','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:16:34.441','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:16:44.451','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:16:54.451','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:17:04.461','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:17:14.481','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:17:24.501','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:17:34.511','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:17:44.545','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:17:54.555','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:18:04.565','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:18:14.575','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:18:24.585','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:18:34.595','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:18:44.615','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:18:54.625','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:19:04.635','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:19:14.645','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:19:24.655','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:19:34.665','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:19:44.692','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:19:54.712','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:20:04.722','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:20:14.732','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:20:24.742','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:20:34.752','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:20:44.762','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:20:54.772','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:21:04.782','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:21:14.802','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:21:24.822','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:21:34.832','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:21:44.854','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:21:54.864','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:22:04.864','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:22:14.874','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:22:24.894','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:22:34.914','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:22:44.924','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:22:54.934','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:23:04.944','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:23:14.954','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:23:24.964','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:23:34.974','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:23:45.011','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:23:55.021','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:24:05.041','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:24:15.051','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:24:25.061','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:24:35.071','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:24:45.071','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:24:55.091','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:25:05.101','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:25:15.121','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:25:25.131','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:25:35.141','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:25:45.160','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:25:55.170','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:26:05.180','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:26:15.190','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:26:25.210','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:26:35.230','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:26:45.240','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:26:55.250','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:27:05.260','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:27:15.270','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:27:25.270','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:27:35.290','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:27:45.315','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:27:55.335','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:28:05.355','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:28:15.355','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:28:25.365','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:28:35.375','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:28:45.385','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:28:55.395','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:29:05.415','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:29:15.435','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:29:25.445','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:29:35.455','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:29:45.474','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:29:55.484','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:30:05.494','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:30:15.514','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:30:25.524','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:30:35.544','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:30:45.554','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:30:55.564','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:31:05.574','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:31:15.584','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:31:25.594','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:31:35.604','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:31:45.638','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:31:55.648','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:32:05.658','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:32:15.668','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:32:25.678','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:32:35.688','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:32:45.698','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:32:55.708','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:33:05.728','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:33:15.748','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:33:25.758','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:33:35.768','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:33:45.786','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:33:55.796','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:34:05.806','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:34:15.826','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:34:25.846','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:34:35.856','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:34:45.866','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:34:55.876','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:35:05.886','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:35:15.896','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:35:25.906','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:36:25.995','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:40:56.329','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:41:06.349','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:44:06.573','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:46:06.705','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:48:26.881','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:49:56.992','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:50:47.062','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:56:47.510','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:56:57.520','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 5:58:17.630','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 6:02:27.946','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 6:02:37.956','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 6:02:47.966','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 6:02:57.976','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 6:03:07.986','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 6:03:18.006','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 6:03:28.016','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:30:00.946','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:30:10.956','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:30:20.966','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:30:30.976','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:30:40.986','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:30:51.018','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:31:01.028','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:31:11.038','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:31:21.048','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:31:31.058','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:31:41.068','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:31:51.078','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:32:01.088','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:32:11.108','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:32:21.118','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:32:31.128','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:32:41.128','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:32:51.153','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:33:01.163','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:33:11.173','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:33:21.183','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:33:31.203','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:33:41.213','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:33:51.223','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:34:01.233','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:34:11.243','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:34:21.253','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:34:31.263','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:34:41.273','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:34:51.308','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:35:01.318','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:35:11.318','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:35:21.328','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:35:31.338','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:36:51.448','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:37:01.458','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:37:11.468','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:37:21.478','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:37:31.498','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:37:41.508','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:37:51.518','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:39:01.600','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:39:11.610','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:39:21.620','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:39:31.630','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:39:41.640','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:39:51.650','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:40:01.660','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:40:11.680','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:40:21.690','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:40:31.690','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:40:41.700','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:40:51.725','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:41:01.735','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:41:11.745','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('14/02/2015 20:41:21.765','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 347981446);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:16:41.699','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:18:01.812','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:20:11.963','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:21:02.023','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:22:02.098','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:24:42.274','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:25:42.362','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:28:52.589','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:30:02.677','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:34:22.984','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:35:23.073','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:36:23.123','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:37:33.215','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:41:53.524','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:42:53.594','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:43:53.671','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:45:03.751','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:49:34.088','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:50:34.158','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:51:44.264','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:54:24.464','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:54:34.474','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:55:44.569','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
Insert into DBA_HIST_ACTIVE_SESS_HISTORY2
   (SAMPLE_TIME, SQL_PLAN_HASH_VALUE)
 Values
   (TO_TIMESTAMP('15/02/2015 1:57:14.688','DD/MM/YYYY fmHH24fm:MI:SS.FF'), 225587999);
COMMIT;

Open in new window


Here the timestamp:

   225587999
1) start:  14/02/2015 5:13:24,197   end:  14/02/2015 5:58:17,630
 2) start:  14/02/2015 20:30:40,986  end:  14/02/2015 20:32:01,088
 3) start: 15/02/2015 1:16:41,699    end: 15/02/2015 1:57:14,688


 347981446
 1) start: 14/02/2015 6:02:27,946   end: 14/02/2015 20:30:30,976
 2) start: 14/02/2015 20:32:11,108  end: 14/02/2015 20:41:21,765

with your query:
select sql_plan_hash_value, min(sample_time), max(sample_time)
  from dba_hist_active_sess_history2
    group by sql_plan_hash_value;

SQL_PLAN_HASH_VALUE      MIN(SAMPLE_TIME)           MAX(SAMPLE_TIME)
-------------------                           -------------------------                   -------------------------
         347981446                  14-FEB-15 06:02:27,946       14-FEB-15 20:41:21,765
         225587999                  14-FEB-15 05:13:24,197       15-FEB-15 01:57:14,688
0
 

Author Comment

by:ralph_rea
ID: 40612442
I'd like to check when SQL_ID change execution plan ORDER BY SAMPLE_TIME
0
 

Author Comment

by:ralph_rea
ID: 40612496
Here is the query that I was looking for:

select num_partition, sql_plan_hash_value, min(sample_time), max(sample_time)
FROM (    
    select a.*, SUM (case when lag_function <> sql_plan_hash_value THEN 1 ELSE 0 END) OVER (ORDER BY sample_time) AS num_partition
    from (    
    select sample_time, sql_plan_hash_value, lag(sql_plan_hash_value,1,0) OVER (ORDER BY sample_time) AS lag_function
  from dba_hist_active_sess_history2
    order by sample_time
  ) a
)  
GROUP BY num_partition, sql_plan_hash_value  
order by 1
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

A company’s centralized system that manages user data, security, and distributed resources is often a focus of criminal attention. Active Directory (AD) is no exception. In truth, it’s even more likely to be targeted due to the number of companies …
A Stored Procedure in Microsoft SQL Server is a powerful feature that it can be used to execute the Data Manipulation Language (DML) or Data Definition Language (DDL). Depending on business requirements, a single Stored Procedure can return differe…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
This video shows how to configure and send email from and Oracle database using both UTL_SMTP and UTL_MAIL, as well as comparing UTL_SMTP to a manual SMTP conversation with a mail server.

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question