Is it possible to specify the last access time of the mysql table? By access, I mean any type of operation in this table, including updating, changing, or even selecting, or any other operation.
Thanks.
You can get the latest update table.
SELECT update_time FROM information_schema.tables WHERE table_name='tablename'
For more verbose (name and database name) plus period (range) try this query:
select table_schema as DatabaseName, table_name as TableName, update_time as LastAccessTime from information_schema.tables where update_time < 'yyyy-mm-dd' group by table_schema order by update_time asc
Use the information_schema database to find which table of the corresponding database has been updated:
SELECT UPDATE_TIME FROM information_schema.tables WHERE TABLE_SCHEMA = 'dbname' AND TABLE_NAME = 'tablename' order by UPDATE_TIME DESC