Database & Lua log errors

Removed references to non-existent or unneeded files.
Fixed the  sql commands to point to the correct tables.