Hello,
On 7/5/11 12:07 PM, Andrade Ricardo (CI/AFU1) wrote:
Hi Daniel, Hi Alex,
Thanks! That looks great. Once commited, I'll test it, too.
By the way, I've just tried with sql_query. It didn't work as well. Do you think it is fixed together with Alex's change?
Shouldn't there be a warning/error message if the returned data type is not supported?
Code: sql_query("openserdb", "SELECT count(*) FROM subscriber where username='foo'", "ra"); $avp(s:value) = $dbr(ra=>[0,0]); xlog("L_INFO", "avp(s:value)=$avp(s:value)\n"); sql_result_free("ra");
Output: avp(s:value)=
interesting, I just looked in the code and bigints should be converted to string values. Can you test if ($dbr(ra=>rows) >0) to be sure there was a row returned by the query.
Cheers, Daniel