• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Updat Query Login

xLosT

Member
Joined
Jan 11, 2010
Messages
1,021
Reaction score
13
Location
Brasil, Rio Grande do Sul
Updat Query Login Erro

PHP:
function onLogin(cid)
db.executeQuery("UPDATE `players` SET `status` = '1' WHERE `id` = " .. getPlayerAccountId(cid) .. ";")
	return 1

end

asdd.jpg
 
LUA:
function onLogin(cid) 
db.query("UPDATE `players` SET `status` = '1' WHERE `id` = " .. getPlayerAccountId(cid) .. ";") 
    return 1 

end
try this
 
Should be
WHERE `account_id` = " .. getPlayerAccountId(cid) .. ";")
If you're gonna use accountId.
 
LUA:
function onLogin(cid) 
db.executeQuery("UPDATE `YOUR_DATABASE_NAME_HERE`.`players` SET `status` = '1' WHERE `id` = " .. getPlayerAccountId(cid) .. ";") 
    return 1 

end

Try this :p
 
Last edited by a moderator:
SQL:
function onLogin(cid) 
db.executeQuery("UPDATE `YOUR_DATABASE_NAME_HERE`.`players` SET `status` = '1' WHERE `id` = " .. getPlayerAccountId(cid) .. ";") 
    return 1 

end

Try this :p

Don't full CAPS please. xD
Also, return true looks more legit than return 1 :p
 
Back
Top