Re: How to keep a timestamp from updating?

From: Date: Thu, 18 Mar 2004 15:22:48 +0000
Subject: Re: How to keep a timestamp from updating?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-180836@lists.php.net to get a copy of this message
Hello Brian, Thursday, March 18, 2004, 3:17:49 PM, you wrote: BD> I have a timestamp field that updates itself with NOW() every time I BD> update the record. I don't want that to happen - I want it to remain as BD> the original creation timestamp. How do I prevent this from happening? Two solutions: 1 - Don't use a timestamp - it's only doing what it is designed to :) 2 - Add another timestamp to your table before the one you want to keep static, i.e. have: modified timestamp, created timestamp Then when you update the table only the first timestamp (modified) will change, created will remain the same. -- Best regards, Richard Davey http://www.phpcommunity.org/wiki/296.html

« previous php.general (#180836) next »