You're not putting anything into the a_List variable anywhere. The getResult() function should add an item into it. Most likely like this (note the use of the nrows() function instead of DBExec() ):
This will return the table as an array of dictionaries:
EDIT: No, sorry, this code won't work either.
local theResult = {} DB:nrows( "SELECT * FROM " .. PluginName .. " WHERE Player = \"" .. player .. "\"", function getResult(a_RowValues) -- add the returned row to our result table: table.insert(theResult, a_RowValues) end ) return theResult
This will return the table as an array of dictionaries:
theResult = { {col1 = val1A, col2 = val2A}, {col1 = val1B, col2 = val2B}, {col1 = val1C, col2 = val2C}, ...}
EDIT: No, sorry, this code won't work either.