Search notes:

Oracle: DBA_HIST_SQL_PLAN

select
   lpad(' ', pln.depth * 2, ' ') || pln.operation || ' ' || pln.options,
   pln.object_owner || '.' || pln.object_name,
   pln.*  
from
   dba_hist_sql_plan pln
where
   pln.sql_id          = '00qdgx1m0v2br'  and
   pln.plan_hash_value =  1199950513      and
-- id = 5                                 and
   pln.con_id = 4
;
with relevant as (
    select
    0 lvl, id, parent_id, operation, options, object_name, object_alias, time, qblock_name, cpu_cost, io_cost, sql_id, timestamp,
    dense_rank() over (order by timestamp desc) r
  from
    dba_hist_sql_plan
  where
    sql_id = '&sql_id'
),
step (lvl, id, operation, options, object_name, object_alias, time, qblock_name, cpu_cost, io_cost, sql_id, r) as (
  select
    0 lvl, id, operation, options, object_name, object_alias, time, qblock_name, cpu_cost, io_cost, sql_id, r
  from
    relevant
  where
    r = 1    and       -- newest timestampe (r=1)
    parent_id is null 
union all
  select
    p.lvl + 1,
    c.id, c.operation, c.options, c.object_name, c.object_alias, c.time, c.qblock_name, c.cpu_cost, c.io_cost, c.sql_id, c.r
  from
    step              p     join
    relevant          c on p.id        = c.parent_id and 
                           p.sql_id    = c.sql_id    and
                           p.r         = c.r
)
select 
  lpad('  ', 2*lvl) ||operation || ' (' || options || ')' op,
  object_name,
  object_alias,
  qblock_name,
  time,
  cpu_cost,
  io_cost
from
  step
order by
  id;
Github repository oracle_scriptlets, path: /ash-awr/awr/plan.sql

TIMESTAMP

The value of timestamp corresponds to the time when the plan was created.
Obviously, this value is the same for a given plan, as can be verified with the following query:
select
   count(distinct timestamp) dts,
-- count(*) cnt,
   sql_id,
   plan_hash_value
from
   dba_hist_sql_plan
where
   dbid = (select dbid from v$database)
group by
   sql_id,
   plan_hash_value
order by
   dts desc;

Misc

Interestingly, the value of the column projection is always null.

See also

Execution plans, plan_table
data dictionary and dba_hist* views.

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/developm...', 1758192202, '216.73.216.150', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/development/databases/Oracle/installed/data-dictionary/hist/sql/plan/index(119): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78