Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Topic started by: JayinGR on January 08, 2010, 01:13:29 PM

Title: SQL Database Error
Post by: JayinGR on January 08, 2010, 01:13:29 PM
I am getting this error when I try an upload the database into the SQL

QuoteError

SQL query:

CREATE TABLE `smf_3log_digest` (
id_topic mediumint( 8 ) unsigned NOT NULL default,
id_msg int( 10 ) unsigned NOT NULL default,
note_type varchar( 10 ) NOT NULL default 'post',
daily smallint( 3 ) unsigned NOT NULL default 0,
exclude mediumint( 8 ) unsigned NOT NULL default 0
) TYPE = MYISAM ;

MySQL said: Documentation
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '
  id_msg int(10) unsigned NOT NULL default ,
  note_type varchar(10) NOT NULL' at line 2

Can someone help me?

Thanks
Title: Re: SQL Database Error
Post by: feline on January 08, 2010, 01:38:30 PM
you have not defined a valur for default ...
id_topic mediumint( 8 ) unsigned NOT NULL default,
id_msg int( 10 ) unsigned NOT NULL default,

better:
id_topic mediumint( 8 ) unsigned NOT NULL default 0,
id_msg int( 10 ) unsigned NOT NULL default 0,

Fel
Title: Re: SQL Database Error
Post by: JayinGR on January 08, 2010, 01:46:40 PM
Thanks for your reply!  How would I fix that?
Title: Re: SQL Database Error
Post by: feline on January 08, 2010, 01:49:19 PM
if you use a mod, call the author. else look at the file on what the code is written...

Fel