[sr-dev] [sqlops] What does sql_query return in case of DB error?

Henning Westerholt henning.westerholt at 1und1.de
Tue Aug 3 15:48:14 CEST 2010


On Monday 02 August 2010, Iñaki Baz Castillo wrote:
> Hi, sqlops module documentation doesn't say what the function
> sql_query returns in case of DB failure. I'll do my tests but if
> somebody knows I would like to know the expected return code.

Hi Iñaki,

it returns this values:

* 1 on succes
* 2 on success, but no result after query
* -1 on failure

modules_k/sqlops/sql_api.c
197:int sql_do_query(struct sip_msg *msg, sql_con_t *con, pv_elem_t *query,

Cheers,

Henning



More information about the sr-dev mailing list