SQLite_UseDatabase Function

Grabs a handle to an SQLite database, creating one if it does not exist.

Unless there are extenuating circumstances, you should consider using "sourcemod-local" as the database name. This provides some unification between plugins on behalf of users.

As a precaution, you should always create some sort of unique prefix to your table names so there are no conflicts, and you should never drop or modify tables that you do not own.

Database SQLite_UseDatabase(const char[] database, char[] error, int maxlength)


const char[] database

Database name.

char[] error

Error buffer.

int maxlength

Maximum length of the error buffer.

Return Value

A database connection Handle, or INVALID_HANDLE on failure. On failure the error buffer will be filled with a message.