[sr-dev] [kamailio/kamailio] DB_UNIXODBC always reports errors for sql queries with no result set (#2810)

kdanderso notifications at github.com
Fri Jul 30 18:18:50 CEST 2021


### Description

SQL queries that do not return a result set (such as INSERT, DELETE, UPDATE) always report errors when using db_unixodbc.  The query succeeds, but the log indicates a failure.

#### Reproduction

Use db_unixodbc.so for sql queries.
Issue a valid query such as INSERT that is not expected to return a result set.

#### Log Messages

ERROR: db_unixodbc [res.c:52]: db_unixodbc_get_columns(): no columns returned from the query
ERROR: db_unixodbc [res.c:253]: db_unixodbc_convert_result(): getting column names failed
ERROR: db_unixodbc [dbase.c:271]: db_unixodbc_store_result(): failed to convert result
ERROR: <core> [db_query.c:197]: db_do_raw_query(): error while storing result
ERROR: sqlops [sql_api.c:297]: sql_do_query(): cannot do the query [DELETE FROM mytable WHERE id = 1]

### Additional Information

Kamailio Version 5.5.0

This issue was also reported to SR-users, but that user did not open an issue. (See https://lists.kamailio.org/pipermail/sr-users/2018-March/100581.html)


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2810
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-dev/attachments/20210730/5c517390/attachment.htm>


More information about the sr-dev mailing list