SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 06/01/2020, 01:13 PM   #1
Hazon
Big Clucker
 
Hazon's Avatar
 
Join Date: May 2018
Location: Who cares ?
Posts: 171
Reputation: 29
Default Creating Table.

Code:
error 037: invalid string (possibly non-terminated string)
error 017: undefined symbol "CREATE"
error 017: undefined symbol "TABLE"
Error is in last line of the table.

Code:
	mysql_query("CREATE TABLE IF NOT EXISTS `gang` (\
		`id` int(10) NOT NULL AUTO_INCREMENT,\
		`name` varchar(30) NOT NULL DEFAULT '-',\
		`tag` varchar(5) NOT NULL DEFAULT '-',\
		`color` int(11) NOT NULL DEFAULT '-1',\
		`founder` varchar(30) NOT NULL DEFAULT '-',\
	    `score` int(10) NOT NULL DEFAULT '0',\
	    PRIMARY KEY (`id`)\
	    ) ENGINE=MyISAM AUTO_INCREMENT=0 DEFAULT CHARSET=latin1;
Hazon is offline   Reply With Quote
Old 06/01/2020, 01:38 PM   #2
ShadowMortar
Big Clucker
 
ShadowMortar's Avatar
 
Join Date: Jul 2016
Location: Croatia
Posts: 168
Reputation: 31
Default Re: Creating Table.

Code:
mysql_query( YOURMYSQL, "CREATE TABLE IF NOT EXISTS `gang` (\
        `id` int(10) NOT NULL AUTO_INCREMENT,\
        `name` varchar(30) NOT NULL DEFAULT '-',\
        `tag` varchar(5) NOT NULL DEFAULT '-',\
        `color` int(11) NOT NULL DEFAULT '-1',\
        `founder` varchar(30) NOT NULL DEFAULT '-',\
        `score` int(10) NOT NULL DEFAULT '0',\
        PRIMARY KEY (`id`)\
        ) ENGINE=MyISAM AUTO_INCREMENT=0 DEFAULT CHARSET=latin1;" );
__________________
Quote:
Originally Posted by CheezIt View Post
Follow your heart and own style.
Feel free to PM me if you need help.
ShadowMortar is offline   Reply With Quote
Old 06/01/2020, 01:43 PM   #3
Hazon
Big Clucker
 
Hazon's Avatar
 
Join Date: May 2018
Location: Who cares ?
Posts: 171
Reputation: 29
Default Re: Creating Table.

tnx.
Hazon is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
HELP! Cannot Creating Table MYSQL AlfaSufaIndo Scripting Help 9 30/05/2018 01:55 PM
MySQL table not creating AndreiWow Scripting Help 1 29/01/2017 12:45 PM
mysql creating table Knekt Scripting Help 4 24/02/2014 09:36 AM
Creating a SQLite table without columns RedFusion Scripting Help 3 29/12/2013 05:39 PM
mysql creating table help RoXONPL Scripting Help 5 09/02/2013 11:38 AM


All times are GMT. The time now is 12:01 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.