Reference to the Database, provided by rorm_db_connect.
Mutable pointer to a transaction, can be null.
Name of the table to query.
Array of columns to retrieve from the database.
Array of joins to add to the query.
Pointer to an FFICondition.
Allows to specify columns to order the result by.
callback function. Takes the context, a row handle and an error that must be checked first.
context pointer to pass through as-is into the callback.
Important: - Make sure that db, model, columns and condition are allocated until the callback is executed.
Differences between these methods: - rorm_db_query_all gets an array of rows, which all need to be processed inside the callback. - rorm_db_query_one gets the first row of the query, throwing if no rows are present. - rorm_db_query_optional gets the first row of the query, or null if there are none.
This function is called completely synchronously.
This function queries the database given the provided parameters.