Auto Date in table

Auto Date in table

am 09.01.2007 10:55:59 von S.Dickson

I have a mysql table, with a field called DATE, how do i get it to
automatilly put the date on it every time a new recored it put on the
table

Date and time would be good,


Tahnks

Re: Auto Date in table

am 09.01.2007 13:57:58 von zac.carey

S.Dickson@shos.co.uk wrote:

> I have a mysql table, with a field called DATE, how do i get it to
> automatilly put the date on it every time a new recored it put on the
> table
>
> Date and time would be good,
>
>
> Tahnks

Have a read through the user comments posted at

http://dev.mysql.com/doc/refman/5.0/en/date-and-time-functio ns.html

Re: Auto Date in table

am 09.01.2007 18:26:27 von Bill Karwin

S.Dickson@shos.co.uk wrote:
> I have a mysql table, with a field called DATE, how do i get it to
> automatilly put the date on it every time a new recored it put on the
> table

You can do this automatically with the TIMESTAMP datatype, but not with
the DATE datatype.

Read the documentation about TIMESTAMP:
http://dev.mysql.com/doc/refman/5.0/en/timestamp-4-1.html

Regards,
Bill K.