CODE
tbl CREATE TABLE `tbl` (
`id` int(10) unsigned NOT NULL auto_increment,
`val` int(10) unsigned NOT NULL default '0',
`t` timestamp(14) NOT NULL,
PRIMARY KEY (`id`)
) TYPE=MyISAM
`id` int(10) unsigned NOT NULL auto_increment,
`val` int(10) unsigned NOT NULL default '0',
`t` timestamp(14) NOT NULL,
PRIMARY KEY (`id`)
) TYPE=MyISAM
Notice the timestamp field.
When I insert a new row using the F11 screen, it works ok: timestamp is set to NULL, which results in writing the current date and time in there. If I go then and change a value on that row, SQLyog issues an UPDATE ... t='<value of timestamp>'.
Is there a way to update the timestamp automatically without me having to explicitely set that field to NULL?
The exact things happen with and without the "NOT NULL" attribute for the timestamp field.
Thanks.
