-- https://docs.oracle.com/en/database/oracle/oracle-database/19/refrn/V-ACTIVE_SESSION_HISTORY.html
-- ashtop examples
-- interesting cols: SQL_OPNAME, time_model_name, top_level_call_name
@ashtop time_model_name,event2,wait_class 1=1 sysdate-1/24/6 sysdate
@dashtop top_level_call_name,event2,wait_class 1=1 "timestamp'2020-07-12 15:38:27'" "timestamp'2020-07-12 16:59:36'"

-- show event description
@sed "log switch"

-- show parameter details
@p sga
@pd sga
-- Display valid parameter values 
@pvalid <parameter_name>

-- show latch statistics
@l redo

-- show SESSION WAIT details for a SID
@s 122

-- sql_id details
@sqlid @sqlid 34mt4skacwwwd %

-- SQL workarea memory and TEMP usage details  
@wrk <condition>
@wrka <condition>
@wrksum <condition>

-- display SQL execution plan line level activity breakdown from ASH
@ash/asqlmon 0sh0fn7r21020 % sysdate-1/24 sysdate

-- ash wait chains
@ash_wait_chains 
@dash_wait_chains 

--  Display background processes
@bg <process_name|process_description>

-- Display redo log layout 
@log

-- Display wait events description 
@sed <event>

-- Display user sessoin and process information
@usid <sid>

-- Display a histogram of the number of waits from MEMORY
@evh <event>
-- Display a histogram of the number of waits from ASH/AWR
@ash/event_hist.sql <event> <filter_expression> <from_time> <to_time>
@ash/devent_hist.sql <event> <filter_expression> <from_time> <to_time>

-- Display lock type info
@lt <lock_name>

-- Search SQL_ID in library cahe 
@sqlt <text>
