[MYSQL] Errors [R5]
#1

I had followed:
Код:
(119) : error 017: undefined symbol "mysql_log"
(276) : error 017: undefined symbol "mysql_format"
(276) : warning 202: number of arguments does not match definition
(276) : warning 202: number of arguments does not match definition
(276) : warning 202: number of arguments does not match definition
(277) : error 017: undefined symbol "mysql_tquery"
(319) : error 017: undefined symbol "mysql_format"
(319) : error 017: undefined symbol "query"
(319) : error 029: invalid expression, assumed zero
(319) : fatal error 107: too many error messages on one line

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


7 Errors.
Reply
#2

Are you including the correct version of mysql's include file?

As it looks to me, as if you forgot to update the include.
Reply
#3

hm..
Reply
#4

At the top of the include file, it will say the version it is.

the Newest one I believe is R41-2 ?

ALSO: LOG_ALL? mysql_log( ERROR | WARNING ); ?

As for the tag mismatch, the function is expecting a string, float or int, and you have passed in something else. As for the query, you just need to create a variable called query that stores the size of the mysql query.
Reply
#5

[R41-2] Error Code.

Код:
(267) : warning 213: tag mismatch
mysql_format(mysql, query, sizeof(query), "SELECT `Password`, `ID` FROM `accounts` WHERE `Name` = '%e' LIMIT 1", playername);
Код:
(268) : warning 213: tag mismatch
  mysql_tquery(mysql, query, "OnAccountCheck", "i", playerid);
Код:
(310) : warning 213: tag mismatch
mysql_format(mysql, query, sizeof(query), "UPDATE `players` SET `SCORE`= %i WHERE `ID` = '%d'", GetPlayerScore(playerid), PlayerInfo[playerid][ID]);
Код:
(311) : warning 213: tag mismatch
mysql_tquery(mysql, query, "", "");
Код:
(590) : warning 213: tag mismatch
mysql_format(mysql, query, sizeof(query), "SELECT * FROM `accounts` WHERE `Name` = '%e' LIMIT 1", playername);
Код:
(591) : warning 213: tag mismatch
mysql_tquery(mysql, query, "OnAccountLoad", "i", playerid);
Код:
(616) : warning 213: tag mismatch
mysql_format(mysql, query, sizeof(query), "INSERT INTO `accounts` (`Name`, `Password`, `IP`, `Admin`, `VIP`, `Money`) VALUES ('%e', '%e', '%e', 0, 0, 0)", playername, PlayerInfo[playerid][Password], playerip);
Код:
(617) : warning 213: tag mismatch
mysql_tquery(mysql, query, "OnAccountRegister", "i", playerid);

Код:
(678) : error 017: undefined symbol "cache_get_field_content_int"
(679) : error 017: undefined symbol "cache_get_field_content_int"
(680) : error 017: undefined symbol "cache_get_field_content_int"
Код:
    PlayerInfo[playerid][pAdmin] = cache_get_field_content_int(0, "Admin");
    PlayerInfo[playerid][VIP] = cache_get_field_content_int(0, "VIP");
    PlayerInfo[playerid][Money] = cache_get_field_content_int(0, "Money");
Reply
#6

Read this: Link

It will explain how to setup and convert your current function to the new system.
Reply
#7

i do not understand, can you give me examples?
Reply
#8

For those tag mismatch warnings, you just need a MySQL tag for your mysql connection variable.
Example:
Код:
new MySQL:mysql;
// ....
and for those undefined symbol errors, cache_get_field_content renamed to cache_get_value_name since R40.
Reply
#9

Quote:
Originally Posted by X337
Посмотреть сообщение
For those tag mismatch warnings, you just need a MySQL tag for your mysql connection variable.
Example:
Код:
new MySQL:mysql;
// ....
and for those undefined symbol errors, cache_get_field_content renamed to cache_get_value_name since R40.
Код:
(669) : warning 202: number of arguments does not match definition
Код:
PlayerInfo[playerid][pVIP] = cache_get_value_name(0, "VIP");
Reply
#10

Код:
cache_get_value_name_int(0, "VIP", PlayerInfo[playerid][pVIP]);
https://sampwiki.blast.hk/wiki/MySQL/R40...get_value_name
Reply


Forum Jump:


Users browsing this thread: 4 Guest(s)