MySQL tip: before dropping a table
Sun 23 Aug 2009 12:44:31 | 1 comments
Check its last modification date, a la filemtime of PHP. How can you do that? Easy:
show table status from DATABASE_NAME like 'TABLE_NAME'G
This gives you an output such as:
mysql> show table status from groups like 'analytics'G
*************************** 1. row ***************************
Name: analytics
Engine: MyISAM
Version: 10
Row_format: Dynamic
Rows: 453161
Avg_row_length: 343
Data_length: 15573804
Max_data_length: 281474976710655
Index_length: 2778112
Data_free: 0
Auto_increment: 158700
Create_time: 2009-08-20 14:26:29
Update_time: 2009-08-23 12:33:49
Check_time: 2009-08-20 14:26:31
Collation: utf8_unicode_ci
Checksum: NULL
Create_options:
Comment:
1 row in set (0.00 sec)
Bold section is the last modification date.
If it's NULL, that means you probably can remove it safely.
Comments
kat
11 months ago
Delete
or



