The display width of the device is not suitable for displaying this website.
Please turn your mobile phone into landscape mode.
<< Back to categories index < Back to threads index
Install error
Schyzo
Registered: on Jul 5th 2016, 8:41
Posts: 3

./../images/avatars/empty.png
^ on Jul 5th 2016, 8:57
Hi !

When I try to install Gnew, I have an error on step 3 :

Code:Error in SQL query "CREATE TABLE gnew_articles ( article_id INTEGER NOT NULL AUTO_INCREMENT, category_id INTEGER NOT NULL DEFAULT '0', user_id INTEGER NOT NULL DEFAULT '0', article_subject CHARACTER VARYING(1280) NOT NULL DEFAULT '', article_text MEDIUMTEXT NOT NULL DEFAULT '', article_creation INTEGER NOT NULL DEFAULT '0', article_edition INTEGER NOT NULL DEFAULT '0', edition_id INTEGER NOT NULL DEFAULT '0', edition_name CHARACTER VARYING(640) NOT NULL DEFAULT '', PRIMARY KEY (article_id) );".

page URL : http://localhost/gnew/install/index.php?step=3&language=french

PHP version : 5.6.18
SQL version : 5.7.11
Schyzo
Registered: on Jul 5th 2016, 8:41
Posts: 3

./../images/avatars/empty.png
^ on Jul 5th 2016, 9:18
I found errors.

SQL had a problem with CHARACTER VARYING and with DEFAULT '' on TEXT and MEDIUM.

I change them and install is good now :)
raoul
Registered: on Apr 1st 2013, 15:08
Posts: 14

./../images/avatars/empty.png
^ on Jul 5th 2016, 20:43
Hello,

What changes have you made ?

I'm working with PHP 5.4.16 and MySQL 5.6.12. Also, with other versions, I never had a problem with the DEFAULT keyword.
Schyzo
Registered: on Jul 5th 2016, 8:41
Posts: 3

./../images/avatars/empty.png
^ on Jul 5th 2016, 22:00
I replaced all 'CHARACTER VARYING' in VARCHAR and delete all DEFAULT '' where type is MEDIUMTEXT and TEXT.

Sorry for my bad english, I'm french.
raoul
Registered: on Apr 1st 2013, 15:08
Posts: 14

./../images/avatars/empty.png
^ on Jul 6th 2016, 7:10
OK.

I don't think that CHARACTER VARYING is the problem since VARCHAR is a shorthand for CHARACTER VARYING.

But on some systems, DEFAULT values on TEXT colums can lead to an error. I will check this.

Thanks
raoul
Registered: on Apr 1st 2013, 15:08
Posts: 14

./../images/avatars/empty.png
^ on Jul 25th 2016, 10:55
Documentation updated: MySQL sql_mode.

If HTML language is enabled and you want to use it, please check start and end tags.

HTML language is disabled