SELECT * FROM(
SELECT ROUND(NVL((ELAPSED_TIME / DECODE(EXECUTIONS, 0, NULL, EXECUTIONS)/1000000 ), 0),3) AS ELAPSED_TIME
, LAST_ACTIVE_TIME
, HASH_VALUE
, SQL_TEXT
FROM V$SQL
WHERE LAST_ACTIVE_TIME >= TO_DATE('20221125', 'YYYYMMDD')
)
WHERE ELAPSED_TIME > 5
ORDER BY ELAPSED_TIME DESC;