Bug #64914 Update_time is NULL for InnoDB tables

Submitted: 9 Apr 2012 9:00 Modified: 15 Sep 2014 5:16
Reporter: xiaobin lin (OCA) Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server: InnoDB storage engine Severity:S4 (Feature request)
Version:5.5 OS:Any
Assigned to: CPU Architecture:Any
Tags: Contribution, table status, Update_time

[9 Apr 2012 9:00] xiaobin lin
Description:
This is duplicated with http://bugs.mysql.com/bug.php?id=14374

I think for tables that are created under innodb_file_per_table mode, we can simply get the mtime of the ibd file, and fill into the result of "show table status"

How to repeat:
show table status like 'innodb table';

Suggested fix:

8023a8024,8035
> 
> 		if (ib_table->space != TRX_SYS_SYSTEM_RSEG_ID)
>		{
>			my_snprintf(path, sizeof(path), "%s/%s%s",
>				mysql_data_home, ib_table->name, ha_innobase_exts[0]);
> 
>			unpack_filename(path,path);
> 
>			if (os_file_get_status(path,&stat_info)) {
>				stats.update_time = (ulong) stat_info.mtime;
>			}
>		}
[9 Apr 2012 19:15] Valeriy Kravchuk
Thank you for the feature request and code contributed.
[15 Sep 2014 5:14] Marko Mäkelä
Posted by developer:
 
WL#6658 implemented update_time for InnoDB tables.
Note that it is not persistent across server restarts.
WL#6917 was filed for making update_time persistent.
[15 Sep 2014 5:16] Marko Mäkelä
This is a duplicate of

Bug#14374 Update_time is NULL for InnoDB tables

The bug was fixed in MySQL 5.7.2.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.057 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.