Greetings,
I used the 'scp' command to copy the file.MYD, file.MYI and file.frm files from one linux box to another linux box.
On the source linux box, the table is like this:
mysql> desc file; +------------------+---------------+------+-----+---------+-------+ | Field | Type | Null | Key | Default | Extra | +------------------+---------------+------+-----+---------+-------+ | file_id | varchar(32) | | PRI | | | | title | varchar(64) | | | | | | user_file_name | varchar(64) | | | | | | system_file_name | varchar(128) | | | | | | path | varchar(255) | | | | | | data | longblob | YES | | NULL | | | size | int(11) | | | 0 | | | filetype | varchar(32) | | | | | | modified | timestamp(14) | YES | | NULL | | +------------------+---------------+------+-----+---------+-------+ 9 rows in set (0.00 sec)
But on the destination linux box, it's like:
mysql> desc file; +------------------+--------------+------+-----+---------+-------+ | Field | Type | Null | Key | Default | Extra | +------------------+--------------+------+-----+---------+-------+ | file_id | varchar(32) | | PRI | | | | title | varchar(64) | | | | | | user_file_name | varchar(64) | | | | | | system_file_name | varchar(128) | | | | | | path | varchar(255) | | | | | | data | longblob | YES | | NULL | | | size | int(11) | | | 0 | | | filetype | varchar(32) | | | | | | modified | timestamp | YES | | NULL | | +------------------+--------------+------+-----+---------+-------+ 9 rows in set (0.00 sec)
Now the time shows as '20030729081900' on the source machine. But the time reads like '2003-07-29 08:19:00' on the destination machine.
Can anybody tell me why the 'modified' field changed from type 'timestamp(14)' to type 'timestamp'? I need to keep the type timestamp(14).
Thanks in advance,
My guess would be that the source server is running a version of MySQL earlier than 4.1, and the destination server is running MySQL 4.1.x.
The TIMESTAMP display format changed in 4.1, and display widths no longer are supported. (In effect, all timestamps are TIMESTAMP(14).)
See:
http://www.mysql.com/doc/en/Upgrading-from-4.0.html
Note particularly the "SQL Changes" section.
-- Paul DuBois, MySQL Documentation Team Madison, Wisconsin, USA MySQL AB, www.mysql.com
MySQL Users Conference: April 14-16, 2004 http://www.mysql.com/uc2004/
-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]