SQL_ThreadQuery

Syntax

native SQL_ThreadQuery(Handle:db_tuple, const handler[], const query[], const data[]="", dataSize=0);

Usage

failstate
- One of the three TQUERY_ defines.
query
- Handle to the query, do not free it.
error
- An error message, if any.
errnum
- An error code, if any.
data
- Data array you passed in.
size
- Size of the data array you passed in.
queuetime
- Amount of gametime that passed while the query was resolving.

public QueryHandler(failstate, Handle:query, error[], errnum, data[], size, Float:queuetime)

Note! The handle you pass in is a DB Tuple, NOT an active connection!
Note! The handle does not need to be freed.
Also note: This function is not guaranteed to be in another thread
 (in fact - it's not).  You're seeing data "after the fact",
 and as such to execute another query you should run
 SQL_ThreadQuery again with new data.

Description

Prepares and executes a threaded query.
This will not interrupt gameplay in the event of a poor/lossed
 connection, however, the interface is more complicated and
 asynchronous.  Furthermore, a new connection/disconnection is
 made for each query to simplify driver support.
The handler should look like: