Hello,
On 03/06/07 09:59, Papadopoulos Georgios wrote:
Hello,
Is there a way to load an integer value into an integer avp using
avp_db_query? For example if in table usr_preferences I have
value='15' and type=1, then using avp_db_load I get an avp with an
int value of 15. Then I can use this int avp to check whether it is
greater or less than some value. I am trying to do the same thing
with avp_db_query but the avp that I get is a string.
that's because in
usr_preferences the values are stored in a string
column. If you make another table and store the value in an integer
column, then it will be stored as integer in AVP.
avp_db_query() takes the type of value from type of column.
Also with 1.1? I just tried avp_db_query() and load an integer column
type from mysql into an AVP, but the AVP is always defined as string.