#define mysql_host "127.0.0.1"
#define mysql_user "root"
#define mysql_password "******"
#define mysql_database "sa-mp"
mysql_connect(mysql_host, mysql_user, mysql_database, mysql_password);
mysql_query("CREATE TABLE IF NOT EXISTS pinfo(user VARCHAR(24), password VARCHAR(40), score INT(20), dinheiro INT(20), IP VARCHAR(16) )");
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
----------
Loaded log file: "server_log.txt".
----------
SA-MP Dedicated Server
----------------------
v0.3z, (C)2005-2014 SA-MP Team
[18:50:06] filterscripts = "" (string)
[18:50:06]
[18:50:06] Server Plugins
[18:50:06] --------------
[18:50:06] Loading plugin: mysql
[18:50:07]
> MySQL plugin R7 successfully loaded.
[18:50:07] Loaded.
[18:50:07] Loaded 1 plugins.
[18:50:07]
[18:50:07] Filterscripts
[18:50:07] ---------------
[18:50:07] Loaded 0 filterscripts.
mysql_connect("mysql_host", "mysql_user", "mysql_database", "mysql_password");
mysql_query("CREATE TABLE IF NOT EXISTS `pinfo`(`user` VARCHAR(24), `password` VARCHAR(40), `score` INT(20), `dinheiro` INT(20), `IP` VARCHAR(16) )");
---------- Loaded log file: "server_log.txt". ---------- SA-MP Dedicated Server ---------------------- v0.3z, ©2005-2014 SA-MP Team [19:05:30] filterscripts = "" (string) [19:05:30] [19:05:30] Server Plugins [19:05:30] -------------- [19:05:30] Loading plugin: mysql [19:05:30] > MySQL plugin R5 successfully loaded. [19:05:30] Loaded. [19:05:30] Loaded 1 plugins. [19:05:30] [19:05:30] Filterscripts [19:05:30] --------------- [19:05:30] Loaded 0 filterscripts. [19:05:32] ---------------------------------- [19:05:32] Blank Gamemode by your name here [19:05:32] ---------------------------------- [19:05:32] Number of vehicle models: 0
mysql_connect("mysql_host", "mysql_user", "mysql_database", "mysql_password");
mysql_connect(mysql_host, mysql_user, mysql_database, mysql_password);
new mysql = mysql_connect(host,user,database,password);
if(mysql_errno(mysql) != 0) print("Vocк nгo conseguio conectar o MySQL !");
ainda continuo tendo problemas amigo, eu adicionei esse comando para certificar que deu para conectar:
pawn Код:
|
penso que isso nгo irб funcionar...
Visto que: O que tб escrito й string e nгo as defines, logo isso vai dar problemas... |