Trying to insert a large number from php to mysql

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi
 
I'm trying to insert the number 1970324970930197 into a mysql BigInt(20)
field.
If I do a direct insert from mysql command prompt and select the record I
get
back the same number.
 
If I do this from PHP I get back 1970324970930000. Notice that the 197 at
the
end is not 000.
 
When echoing the number in php it looks like : 1.970324970930E+15 so I'm 
guessing  this is the reason why the 3 Zeros are added instead of the 197 
at the end.
 
How can I avoid this and actually pass the real number to mysql?
 
thanks

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux