Jump to content

the default date setting at creating table


patricksky

Recommended Posts

I have the following creat table script

 


create table event(

event_id varchar(9) primary key,

title varchar(30) not null,

description text,

photo_dir varchar(8),

date date not null default CURRENT_DATE

);

 

when i run this script, the error occur that related to the CURRENT_DATE. the purpose of the date colume set to default current_date is that if user haven\'t given the date, then set this as system current date.

what is the error using CURRENT_DATE ?

Thx~

Link to comment
https://forums.phpfreaks.com/topic/760-the-default-date-setting-at-creating-table/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.