mysql issues...
#1

whats wrong with this:
pawn Код:
new MySQL:connection = mysql_init(LOG_ALL, 1);
mysql_connect(MYSQL_HOST, MYSQL_USER, MYSQL_PASS, MYSQL_DB, connection, 1);
mysql_query("CREATE TABLE IF NOT EXISTS `test_table` (\`test_int` INT( 2 ) NOT NULL DEFAULT '0')", -1); //this line has the error!
mysql_close(connection);
errors:
Код:
C:\Documents and Settings\Matt\Desktop\chedder's freeroam\gamemodes\CHEDDER.pwn(74) : error 027: invalid character constant
C:\Documents and Settings\Matt\Desktop\chedder's freeroam\gamemodes\CHEDDER.pwn(74) : error 027: invalid character constant
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors.
WTH?
Reply
#2

You have the escape character in your string for some reason, take it out.

Note: The escape character is "\" without the quotes.

P.S: Apologies for spam, removed the extra post
Reply
#3

thats a bit of a spam. lol. thx man!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)