Promises, even when resolved/rejected immediately after their creation, will
destroy any useful information from a stack trace when used over
events/exports.
Since some people still use the exports rather than MySQL/lib.lua, and for
some reason don't know the correct syntax for Lua exports (i.e. using
exports.oxmysql.query instead of the CORRECT exports.oxmysql:query) it's
comically common for an "untraceable" error to get spit out.
Will this help? No. Will everyone expect me to solve their issues? Yes.
Go update your scripts to use MySQL/lib.lua and we can all get along
stress-free.
Lua tables are msgpacked with the "without_hole" setting.
Nested tables being sent with "prepare" failed to account for
nil values in tables unpacking into objects.
BLOB's with a value of null cannot be iterated, resulting in an
error while trying to return [...field.buffer()].
Minor change to weird typecasting on date values.
Parse each value while iterating prepared statements, ensuring
objects are remapped to arrays and NULL values are properly
inserted.
Utilise transactions to rollback changes in the event of an error.
Lua tables are msgpacked with the 'without_hole' setting, resulting
in an object. rawQuery already handles this and converts an object
into an array (filling null where appropriate).
Give rawExecute the same treatment.
Other resources with script errors (notably "attempt to index a nil value") would mistakenly report the query as failed, and people would assume ANY reported errors were because of oxmysql, even through it was their own awful script.
No errors should be thrown in oxmysql when an error occurs in a function reference.