Jump to content

Question with dbEex


HustraDev

Recommended Posts

Posted

i have problem in this code

acc = getPlayerAccount(source) 
    connection = dbConnect( "sqlite", "database.db" ) 
       dbExec( connection, "INSERT INTO VList VALUES(account,id,name,price)", "ss",22,"sso",9876782) 
  

> i want to insert into [ VList ] table a row's that include [ acc ] that is a Player account how i can do that? :arrowleft:

Posted

Im not an exper (Im noob at db functions) but maybe this could be usefull

dbExec( connection, "INSERT INTO `VList` (`colum1`, `colum2`) VALUES (`"..value1.."`,`"..value1.."`)" ) 

Sorry if it didn help u.

Regards.

Posted

getPlayerAccount is returning false, make sure source is a player and that they are not a guest account.

Also, you'll want to get the account name - not the element itself as it would return userdata, not a string with the name.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...