Oracle: how to get the latest DDL update time

I tried the following SQL:

SELECT * FROM all_objects

But it also updates the LAST_DDL_TIME column of the above table whenever any other table grant is provided.

I want the last DDL update time for the table to change only.

+4
source share
3 answers

Ketan, I think DDL triggers will solve your problems.

More on this: http://www.dba-oracle.com/t_ddl_triggers.htm

+4
source

If you use a trigger to monitor DDL, you essentially duplicate the functionality already provided through Oracle Auditing.

http://docs.oracle.com/cd/B28359_01/server.111/b28286/statements_4007.htm

10- : https://oracle-base.com/articles/10g/auditing-10gr2

+1

:

SELECT object_name, object_type, last_ddl_time
FROM dba_objects 
WHERE owner = <<table owners name>>
AND object_name = 'yourTableName'
0
source

Source: https://habr.com/ru/post/1606910/


All Articles