I was using the Lua 5.1 package and it worked good but crashed on app exit.
Now i'm changing to the ODMC plugin and i'm having some problems
here is what i have and if you can help please do.
I do get a good connection using the new ODBC plugin but when i do a query i get a error like "attempt to compare a number with nil".
tbInfo = ODBC.OpenQuery("SELECT * FROM users ");
if tbInfo and nRows > 0 then
for i,v in tbInfo.Data do
checkuser = tbInfo.Data[i]["username"]
checkpassword = tbInfo.Data[i]["password"]
end
end
All i did was change this: (old)
With this: (new)tbInfo = MySQLQueryToTable("SELECT * FROM users ");
It seems to me that the new line (ODBC) the tbInfo will result in a 0 or 1 and the old line will bring back a table with all the usernames and passwords.tbInfo = ODBC.OpenQuery("SELECT * FROM users ");
Please help if you can
Thanks
Jean

Reply With Quote
