[Tutorial] MySQL Registration System [Threaded Queries(R33+) + Whirlpool]
#43

Errors!! Please help me, I copied everything from the tutorial...

Code:
C:\Users\Adi\Desktop\Test\gamemodes\Mysql.pwn(67) : error 017: undefined symbol "mysql"
C:\Users\Adi\Desktop\Test\gamemodes\Mysql.pwn(67) : error 017: undefined symbol "host"
C:\Users\Adi\Desktop\Test\gamemodes\Mysql.pwn(68) : error 017: undefined symbol "mysql"
C:\Users\Adi\Desktop\Test\gamemodes\Mysql.pwn(89) : error 001: expected token: ";", but found "-identifier-"
C:\Users\Adi\Desktop\Test\gamemodes\Mysql.pwn(89) : error 017: undefined symbol "Name"
C:\Users\Adi\Desktop\Test\gamemodes\Mysql.pwn(89) : warning 215: expression has no effect
C:\Users\Adi\Desktop\Test\gamemodes\Mysql.pwn(89) : error 001: expected token: ";", but found "]"
C:\Users\Adi\Desktop\Test\gamemodes\Mysql.pwn(89) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


7 Errors.
Lines With the errors:
Code:
public OnGameModeInit()
{
	mysql_log(LOG_ERROR | LOG_WARNING | LOG_DEBUG); 
    mysql = mysql_connect(host, user, db, pass);  // Line 67
    if(mysql_errno(mysql) != 0) print("Could not connect to database!"); // Line 68
	AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
	return 1;
}

public OnPlayerConnect(playerid)
{
    new query[128]
    GetPlayerName(playerid, Name[playerid], 24); // Line 89
    GetPlayerIp(playerid, IP[playerid], 16);
    mysql_format(mysql, query, sizeof(query),"SELECT `Password`, `ID` FROM `players` WHERE `Username` = '%e' LIMIT 1", Name[playerid]);
    mysql_tquery(mysql, query, "OnAccountCheck", "i", playerid);
	return 1;
}
I already have these defined:
Code:
#define host    "localhost" 
#define user    "root" 
#define db      "server" 
#define pass    "" 

//dialogs
#define dregister    6287 //dialog register id
#define dlogin        6288 // ^

static
    mysql, //This variable will be used to manage our database
    Name[MAX_PLAYERS][24], //We will use this variable to store player's name.
    IP[MAX_PLAYERS][16] //We will use this variable to store player's ip.
    ;
    
native WP_Hash(buffer[], len, const str[]); 


enum PDATA
{
    ID, 
    Password[129], 
    Admin, 
    VIP,
    Money, 
    Float:posX, 
    Float:posY, 
    Float:posZ

}
new pInfo[MAX_PLAYERS][PDATA]; //Variable that stores enumerator above
Reply


Messages In This Thread
MySQL Registration System [Threaded Queries + Whirlpool] - by newbienoob - 05.01.2014, 05:36
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by SyntaxQ - 05.01.2014, 05:46
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Ryan_Bowe - 05.01.2014, 07:19
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Lordzy - 05.01.2014, 07:27
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by iZN - 05.01.2014, 07:30
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by newbienoob - 05.01.2014, 09:51
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by dusk - 05.01.2014, 10:34
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by ]Rafaellos[ - 06.01.2014, 07:08
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by iZN - 06.01.2014, 07:20
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Vince - 06.01.2014, 10:10
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Konstantinos - 06.01.2014, 10:34
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by maddinat0r - 06.01.2014, 16:33
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by anou1 - 06.01.2014, 19:19
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Konstantinos - 06.01.2014, 19:40
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by anou1 - 06.01.2014, 19:44
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by newbienoob - 07.01.2014, 03:04
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by anou1 - 07.01.2014, 18:26
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by iZN - 07.01.2014, 18:59
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by anou1 - 07.01.2014, 19:05
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by PowerPC603 - 27.01.2014, 13:20
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Konstantinos - 27.01.2014, 13:33
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Konstantinos - 04.02.2014, 21:00
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Blast3r - 04.02.2014, 21:08
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by PowerPC603 - 04.02.2014, 21:36
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Dorito - 08.02.2014, 07:07
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Zinedine - 08.02.2014, 16:18
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Konstantinos - 08.02.2014, 16:23
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Zinedine - 08.02.2014, 16:25
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Zinedine - 09.02.2014, 00:12
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Ryan_Undering - 20.02.2014, 17:21
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Konstantinos - 20.02.2014, 17:29
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by jordyvc - 25.03.2014, 16:04
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Konstantinos - 25.03.2014, 16:13
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by newbienoob - 25.03.2014, 16:17
Re : MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Cam972 - 25.03.2014, 17:01
Re: Re : MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by newbienoob - 25.03.2014, 17:18
Re : MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Cam972 - 25.03.2014, 18:10
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Konstantinos - 25.03.2014, 19:50
Re : MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Cam972 - 28.03.2014, 17:53
Re : MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Cam972 - 30.03.2014, 17:04
Re : MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Maxime_Creteur - 05.04.2014, 07:50
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Thomixio - 24.07.2014, 17:40
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by adithegman - 25.08.2014, 09:04
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by FlipperK119 - 29.08.2014, 22:12
AW: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by klaus1n3 - 21.09.2014, 03:20
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by JeaSon - 21.09.2014, 05:29
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by TakeiT - 21.09.2014, 06:03
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Baltimore - 21.09.2014, 13:52
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by WopsS - 21.09.2014, 13:53
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Baltimore - 21.09.2014, 14:05
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by JeaSon - 22.09.2014, 06:29
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by StegooPs - 25.09.2014, 11:02
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Justinclaveria123 - 10.10.2014, 08:39
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by zwoorelook - 11.10.2014, 17:03
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Vince - 11.10.2014, 18:31
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Ryz - 06.01.2015, 04:55
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Bondage - 13.01.2015, 13:54
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by AgusZ - 16.01.2015, 05:54
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by VenomMancer - 01.02.2015, 12:16
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Nicker - 01.02.2015, 12:41
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by VenomMancer - 02.02.2015, 10:25
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by AchievementMaster360 - 05.03.2015, 02:24
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by AroseKhanNiazi - 09.03.2015, 10:05
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Dorito - 21.03.2015, 09:26
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by BR3TT - 30.03.2015, 13:57
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by BleverCastard - 30.03.2015, 15:01
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by BR3TT - 30.03.2015, 22:56
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by naveen - 20.04.2015, 10:21
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by BleverCastard - 20.04.2015, 15:50
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by naveen - 04.05.2015, 14:18
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by DarkLouis - 07.05.2015, 16:26
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Konstantinos - 07.05.2015, 16:29
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by DarkLouis - 07.05.2015, 16:31
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by DarkLouis - 07.05.2015, 16:38
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by DarkLouis - 07.05.2015, 16:59
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by BigGroter - 16.05.2015, 23:24
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Jihanz - 14.11.2015, 12:55
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by Celirius - 15.04.2016, 22:35
Re: MySQL Registration System [Threaded Queries(R33+) + Whirlpool] - by BennyX - 26.12.2016, 18:31

Forum Jump:


Users browsing this thread: 1 Guest(s)