[OpenSER-Devel] [ openser-Bugs-1954586 ] postgres: bogus error on empty avp_db_query

SourceForge.net noreply at sourceforge.net
Thu May 8 18:53:51 CEST 2008


Bugs item #1954586, was opened at 2008-04-30 00:38
Message generated for change (Settings changed) made by henningw
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=743020&aid=1954586&group_id=139143

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver 1.3.x
>Status: Open
>Resolution: None
Priority: 5
Private: No
Submitted By: Ovidiu Sas (osas)
Assigned to: Henning Westerholt (henningw)
Summary: postgres: bogus error on empty avp_db_query

Initial Comment:
If a query is performed on a postgres db using the avp_db_query() and the query returns no rows, the following bogus error is printed on the logs:
ERROR:postgres:pg_convert_rows: no rows requested from the query
If the query is returning something, then no errors are printed out.


Regards,
Ovidiu Sas

----------------------------------------------------------------------

>Comment By: Henning Westerholt (henningw)
Date: 2008-05-08 16:53

Message:
Logged In: YES 
user_id=337916
Originator: NO

Reopen Bug, because on trunk the partitioning of fetch_result don't work
anymore. I'll investigate..

Henning

----------------------------------------------------------------------

Comment By: Henning Westerholt (henningw)
Date: 2008-05-08 16:30

Message:
Logged In: YES 
user_id=337916
Originator: NO

Hi Ovidiu,

for 1.3 i moved the check to the pg_convert_result function, and also
silenced the log message. It should work now, please test.

For the trunk i refactored the db_postgres_convert_rows function somewhat,
the error message should also not happen here anymore.

Please reopen if you still see issues.

Cheers,

Henning

----------------------------------------------------------------------

Comment By: Henning Westerholt (henningw)
Date: 2008-04-30 14:08

Message:
Logged In: YES 
user_id=337916
Originator: NO

Hi Ovidiu,

this error message is in fact emitted for every empty query. I reviewed
the code of the function in question, and found some additional issues.
I'll take care of this.

Cheers,

Henning

----------------------------------------------------------------------

Comment By: Ovidiu Sas (osas)
Date: 2008-04-30 00:45

Message:
Logged In: YES 
user_id=1395524
Originator: YES

dbase.c:pg_fetch_result() checks the number of rows before calling
pg_convert_rows()
db_res.c:pg_convert_result() doesn't check if the number of rows is 0
(only <0 check is performed) before calling pg_convert_rows()

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=743020&aid=1954586&group_id=139143



More information about the Devel mailing list