• 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!

Please fix this db.query edit !!! Easy + reppp

Blood BlvD Ot

Member
Joined
Jun 12, 2010
Messages
243
Reaction score
7
db.executeQuery("UPDATE `accounts` SET `page_access` = 0, `page_lastday` = 1293581300, `email_new` = [email protected], `rlname` = noName, `location` = BloodBlvdOt WHERE `id` ='"..id.."';")
 
LUA:
db.executeQuery("UPDATE `accounts` SET `page_access` = 0, `page_lastday` = 1293581300, `email_new` = '[email protected]', `rlname` = 'noName', `location` = 'BloodBlvdOt' WHERE = '"..id)
 
[28/12/2010 20:59:48] mysql_real_query(): UPDATE `accounts` SET `page_access` = 0, `page_lastday` = 1293581300, `email_new` = '[email protected]', `rlname` = 'noName', `location` = 'BloodBlvdOt' WHERE = '0 - MYSQL ERROR: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '= '0' at line 1 (1064)


what local would i put for "..id ?


local id = getAccountIdByName(playerName) ????
 
lulz pwna
LUA:
db.executeQuery("UPDATE `accounts` SET `page_access` = 0, `page_lastday` = 1293581300, `email_new` = '[email protected]', `rlname` = 'noName', `location` = 'BloodBlvdOt' WHERE id = '" .. id)

[28/12/2010 20:59:48]
what local would i put for "..id ?


local id = getAccountIdByName(playerName) ????

LUA:
local id = getPlayerAccountId(cid)
 
NEVER MIND I FIGURED IT OUT :D

Code:
function onUse(cid, item, frompos, item2, topos)
----Config----
local playerName = getPlayerName(cid)
local id = getAccountIdByName(playerName)
local storage = getPlayerStorageValue(cid,15424)
---/Config----
	if isPlayer(cid) and storage == -1 and id <= 2497 then
		db.executeQuery("UPDATE `accounts` SET `page_access` = 0, `page_lastday` = 1293581300, `email_new` = '[email protected]', `rlname` = 'noName', `location` = 'BloodBlvdOt' WHERE `id` ='"..id.."';") 
		setPlayerStorageValue(cid,15424,1)
	else
		doPlayerSendCancel(cid,"You have already fixed your account to be able to access the site propperly")
	end 
return true 
end

TANX FOR HELPS :D
 
Last edited:
why old params :s
LUA:
function onUse(cid, item, fromPosition, itemEx, toPosition)
	----Config----
	local id = getPlayerAccountId(cid)
	local storage = getCreatureStorage(cid, 15423)
	---/Config----
	if storage == EMPTY_STORAGE and id <= 2497 then
		db.executeQuery("UPDATE `accounts` SET `page_access` = 0, `page_lastday` = 1293581300, `email_new` = '[email protected]', `rlname` = 'noName', `location` = 'BloodBlvdOt' WHERE `id` = " .. id)
		doCreatureSetStorage(cid,15423,1)
	else
		return doPlayerSendCancel(cid, 'You have already fixed your account to be able to access the site properly.')
	end 
	return true 
end
 
Why don't you just execute this in your DB?
SQL:
UPDATE `accounts` SET `page_access` = 0, `page_lastday` = 1293581300, `email_new` = '[email protected]', `rlname` = 'noName', `location` = 'BloodBlvdOt';
 
That fucking lua whore executes all my queries ingame -.- xd urs should work then cyber
 
Back
Top