11.05.2017, 08:07
pawn Код:
MySQLConnect()
{
g_iHandle = mysql_connect(SQL_HOSTNAME, SQL_USERNAME, SQL_DATABASE, SQL_PASSWORD);
switch(mysql_errno(g_iHandle) != 0)
{
case 1:
{
printf("Connection to %s database failed. Server is shuting down...", SQL_DATABASE);
SendRconCommand("exit");
}
case 0: printf("Connection to %s database with %s user, has been established.", SQL_DATABASE, SQL_USERNAME);
}
return 1;
}
I made a script for you, to use it, if you want to be easier ( without that unicode thing ).
And, when you make a new database, you can let collation to default, not change it ( https://gyazo.com/59e45b7c1779acb59571c7629bceffb0 ).
I hope I helped you.
+rep if you want, if this thing works?