Adding `$_sql` to exception message to improve error reporting.