[kronolith] error in your SQL syntax near 'NOW() NOT NULL

Jan Schneider jan@horde.org
Mon, 10 Dec 2001 10:41:28 +0100


Zitat von Pavel Chytil <paja@asp.ogi.edu>:

>  Hello,
> 
>  I have tried to create table for kronolith (using
> kronolith/docs/kronolith.sql
>  from cvs) in mysql and get following error:
> 
>  mysql> CREATE TABLE kronolith_events (
>      ->     event_id bigint DEFAULT 0 NOT NULL,
>      ->     calendar_id varchar(255) NOT NULL,
>      ->     event_description text,
>      ->     event_location text,
>      ->     event_keywords text,
>      ->     event_title varchar(80),
>      ->     event_category varchar(80),
>      ->     event_recurtype varchar(11) DEFAULT '0',
>      ->     event_recurinterval varchar(11),
>      ->     event_recurdays varchar(11),
>      ->     event_recurenddate datetime,
>      ->     event_start datetime DEFAULT NOW() NOT NULL,
>      ->     event_end datetime DEFAULT NOW() NOT NULL,
>      ->     event_alarm int DEFAULT 0,
>      ->     PRIMARY KEY (event_id)
>      -> );
>  ERROR 1064: You have an error in your SQL syntax near 'NOW() NOT NULL,
>      event_end datetime DEFAULT NOW() NOT NULL,
>      event_alarm i' at line 13
>  mysql>

We're still trying to find cross database compatible sql statements. No 
luck! :-/
Remove the DEFAULT NOW() part or replace it with DEFAULT '0000-00-00 
00:00:00'

Jan.

::::::::::::::::::::::::::::::::::::::::
AMMMa AG - discover your knowledge
:::::::::::::::::::::::::::
Detmolder Str. 25-33 :: D-33604 Bielefeld
fon +49.521.96878-0 :: fax  +49.521.96878-20
http://www.ammma.de
::::::::::::::::::::::::::::::::::::::::::::::