Hello all,
I have an ar model defined over a postgresql table. There is a field, weight that is stored as 'real' in database. After loading a record from db this field is retrieved as a php string instead of php double.
Example: in db I have 1.21 when loading it in the ar it is stored as "1.21" instead of 1.21.
Is this intendted behavior? If yes why? Because integers are converted to integers when fetched from db.
Thank you,
-soso
Page 1 of 1
ActiveRecord attributes binding after find
#2
Posted 23 June 2010 - 06:55 AM
numeric data are represented with string in the AR...
check this thread - http://www.yiiframew...__fromsearch__1
check this thread - http://www.yiiframew...__fromsearch__1
Find more about me.... btw. Do you know your WAN IP?
#3
Posted 23 June 2010 - 07:00 AM
mdomba, on 23 June 2010 - 06:55 AM, said:
numeric data are represented with string in the AR...
check this thread - http://www.yiiframew...__fromsearch__1
check this thread - http://www.yiiframew...__fromsearch__1
Hi, it's not numeric, it's real, which is represented as double.
Share this topic:
Page 1 of 1

Help












