I can't see anything wrong with the PHP code, and according to the output you posted, MySQL is passing PHP the 0 value.
So, you need to figure our why that is happening.
Can you execute queries on your database via a command line, or something similar?
Try seeing exactly how your table structure is from MySQL's point of view, by doing:
[code=mysql]SHOW CREATE TABLE alarmnotificati ondetail[/code]
Post that here. Maybe there is some problem with the types you use for your fields.
And select a few of the rows in that table that contain the values that are not displaying correctly. See if MySQL actually returns the correctly.
That way we can know for sure whether the data is getting lost in transition or whether it is simply not stored correctly.
So, you need to figure our why that is happening.
Can you execute queries on your database via a command line, or something similar?
Try seeing exactly how your table structure is from MySQL's point of view, by doing:
[code=mysql]SHOW CREATE TABLE alarmnotificati ondetail[/code]
Post that here. Maybe there is some problem with the types you use for your fields.
And select a few of the rows in that table that contain the values that are not displaying correctly. See if MySQL actually returns the correctly.
That way we can know for sure whether the data is getting lost in transition or whether it is simply not stored correctly.
Comment