Započeo PabloK
•8. Maj 2020.MySQL Inline
1,162
pregleda
1
postova
Shot Caller
Balkan SA:MP
SA-MP Doprinos
Balkan SA:MP
SA-MP DoprinosNovi Član
90 / 100 XP
Početnik(0)
101
Postovi:
11
Teme:
Pridružio se:Maj 2020
8. Maj 2020.
MySQL Inline
Šta je MySQL Inline?
To je jedna od mogućnosti koja dolazi uz y_inline koja Vam omogućava da u istoj funkciji bez kreiranja novih callbackova kreirate MySQL Cache.
Iz čega se MySQL Inline sastoji?
Sastoji se iz 2 funkcije:
MySQL_PQueryInline(MySQL:handle, Func:cb<>, const query[], GLOBAL_TAG_TYPES:...)
MySQL_TQueryInline(MySQL:handle, Func:cb<>, const query[], GLOBAL_TAG_TYPES:...)Kako se MySQL Inline funkcije koriste?
// -> Database query
inline loadAccount()
{
// Clear Chat Box
ClearChat(playerid, 16);
// Should we redirect user to registration?
if(!cache_num_rows())
return RegisterProcessHandler(playerid);
cache_get_value_name_int(0, "account_id", PlayerDBID);
cache_get_value_name(0, "account_password", PlayerPassword);
cache_get_value_name(0, "account_mail", PlayerMail);
}
MySQL_TQueryInline(dbHandler, using inline loadAccount, "SELECT * FROM `player_account` WHERE `account_username` = '%e' LIMIT 1", PlayerUsername);
Morate biti prijavljeni da biste odgovorili na ovu temu.
Prijava