MySQL database creation - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: MySQL database creation (
/showthread.php?tid=609647)
MySQL database creation -
NeXoR - 15.06.2016
Hey guys
I'm working on an Admin mysql based filterscript which I plan to release here
I've done all the Admin registration phase and I wanted to test it but the mysql sent errors in this line:
PHP Code:
(error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ') ENGINE = InnoDB DEFAULT CHARSET = latin1' at line 1
So, I tried to debug it and run the command on the database itself using phpMyAdmin
It claims that and I quote:
Code:
"Unrecognized data type: ENGINE"
Like this word doesn't exist in SQL language
Is there a new name ?
SQL Code:
PHP Code:
CREATE TABLE IF NOT EXISTS `Admins` ( "\
"`Username` varchar(24) NOT NULL," \
"`AdminLevel` int(1) NOT NULL," \
"`IP` varchar(16) NOT NULL," \
"`APassword` varchar(256) NOT NULL," \
"`ALogin` int(1) NOT NULL," \
") ENGINE = InnoDB DEFAULT CHARSET = latin1
Re: MySQL database creation -
zPain - 15.06.2016
Remove the comma at the end of the "ALogin" line.
PHP Code:
`ALogin` int(1) NOT NULL -- No comma here
Re: MySQL database creation -
NeXoR - 15.06.2016
Quote:
Originally Posted by zPain
Remove the comma at the end of the "ALogin" line.
PHP Code:
`ALogin` int(1) NOT NULL -- No comma here
|
Ugh, those tiny problems which can freak you out ..
Thanks