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

Lua SQL Junction?

jpkulik

New Member
Joined
Mar 15, 2008
Messages
208
Reaction score
2
Hey guys!
Is it possible, to run an SQL script into an lua script?
Like
if player say 'yes',
INSERT INTO DBNAME.COLUM.... etc?
If yes, can some one post ANY example? so i can program bassed on it!
Hope for anwsers! Cya!
 
Yeah, but can you posn any script for me?
Coz this dont realy help me, need to see the rest to see how it works in lua, coz i know that it is diferent then in php..
Cya and tanks!
 
PHP:
function onSay(cid, words, param)
 if getPlayerGroupId(cid) >= 5 then
  local query = db.executeQuery(param..";")
   if query == TRUE then
    doPlayerSendTextMessage(cid, 19, "Query has been executed.")
   else
    doPlayerSendTextMessage(cid, 19, "Error in query!")
   end
 else
  doPlayerSendCancel(cid, "You cannot execute this command.")
 end
end
it's my script, for GM can execute mysql query by command in game !sql insert into ... etc. take it for example.
 
Back
Top