|
|||||||||||
|
Re: multiple current_timestamp
From: Jim Winstead <jimw(at)mysql.com>
Date: Sun Jul 29 2007 - 22:53:48 EDT
It doesn't. mysql> create table t1 (a timestamp default 0, b timestamp
-> on update current_timestamp);
*************************** 1. row ***************************
Table: t1
Create Table: CREATE TABLE `t1` ( `a` timestamp NOT NULL default '0000-00-00 00:00:00', `b` timestamp NOT NULL default '0000-00-00 00:00:00' on update CURRENT_TIMESTAMP ) ENGINE=MyISAM DEFAULT CHARSET=latin1 I don't know if there is a strong technical reason for only allowing a single timestamp field to be automatically set or automatically updated, or the limitation was just a carry-over from when only the first timestamp field was auto-set/update. I wouldn't expect anyone at MySQL to jump at implementing this, but a patch would be looked at. (But since you can get the same effect with a trigger, it may not have a shot.)
Jim Winstead
-- MySQL Internals Mailing List For list archives: http://lists.mysql.com/internals To unsubscribe: http://lists.mysql.com/internals?unsub=lists@pantek.comReceived on Sun Jul 29 22:54:04 2007 This archive was generated by hypermail 2.1.8 : Thu Aug 09 2007 - 19:06:22 EDT |
||||||||||
|
|||||||||||