:crying: :book: :dipser:
Ciao a tutti, mi sono appena iscritto al forum perchè avvicinato solo da poco al PHP e ho un problema col database (che ho su Aruba).
Il MySql mi da un messaggio d'errore quando cerco di creare le seguenti tabelle:
mysql_query("CREATE TABLE `commenty` (
`commid` int(5) NOT NULL auto_increment,
`main` tinyint(1) NOT NULL,
`text` text collate utf8_unicode_ci,
`linkurl` text collate utf8_unicode_ci,
`date` datetime NOT NULL,
`text1` text collate utf8_unicode_ci,
PRIMARY KEY (`commid`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1")
or die(mysql_error());
mysql_query("CREATE TABLE `adminyy` (
`userid` int(5) NOT NULL auto_increment,
`username` varchar(55) collate utf8_unicode_ci default NULL,
`password` varchar(55) collate utf8_unicode_ci default NULL,
PRIMARY KEY (`userid`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1")
or die(mysql_error());
Il messaggio d'errore è il seguente:
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 'collate utf8_unicode_ci, `linkurl` text collate utf8_unicode
Che sia un problema di compatibilità di caratteri col database?
P.S.
Sto cercando di installare lo script per commenti Comments 1.1 ( http://phpform.net/comment.php )
Qualche anima pia in giro disposta ad aiutarmi?
Ciao a tutti, mi sono appena iscritto al forum perchè avvicinato solo da poco al PHP e ho un problema col database (che ho su Aruba).
Il MySql mi da un messaggio d'errore quando cerco di creare le seguenti tabelle:
mysql_query("CREATE TABLE `commenty` (
`commid` int(5) NOT NULL auto_increment,
`main` tinyint(1) NOT NULL,
`text` text collate utf8_unicode_ci,
`linkurl` text collate utf8_unicode_ci,
`date` datetime NOT NULL,
`text1` text collate utf8_unicode_ci,
PRIMARY KEY (`commid`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1")
or die(mysql_error());
mysql_query("CREATE TABLE `adminyy` (
`userid` int(5) NOT NULL auto_increment,
`username` varchar(55) collate utf8_unicode_ci default NULL,
`password` varchar(55) collate utf8_unicode_ci default NULL,
PRIMARY KEY (`userid`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1")
or die(mysql_error());
Il messaggio d'errore è il seguente:
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 'collate utf8_unicode_ci, `linkurl` text collate utf8_unicode
Che sia un problema di compatibilità di caratteri col database?
P.S.
Sto cercando di installare lo script per commenti Comments 1.1 ( http://phpform.net/comment.php )
Qualche anima pia in giro disposta ad aiutarmi?