SQT
A C++ ORM framework for SQLite
Loading...
Searching...
No Matches

◆ SQT_THROW_IF_SQL_ERROR

#define SQT_THROW_IF_SQL_ERROR ( error_code,
db_handle )
Value:
if (error_code != SQLITE_OK) sqt::ThrowSQLError(error_code, db_handle);
void ThrowSQLError(int error_code, sqlite3 *db_handle)
A helper function to throw the sqt::SQLError exception.
Definition sql_error.h:53

A helper macro to throw the sqt::SQLError exception if the specified error code is not SQLITE_OK.

Parameters
error_codeThe error code returned by SQLite functions.
db_handleThe SQLite database handle from which the error message is retrieved.