Re: Cannot convert value '0000-00-00 00:00:00' from column 4 to TIMESTAMP
The second major problem I am running into after the upgrade is the following error, which did not occur on Development. Error Executing Database Query. Cannot convert value '-00-00 00:00:00' from column 4 to TIMESTAMP. The error occurred on line 8. MySQL version is: 5.0.27 Thanks in advance for any help. I don't know what/how are you doing and I don't even know enough about the subject but: From PHP manual @ http://pt.php.net/manual/en/function.strtotime.php: Note: The valid range of a timestamp is typically from Fri, 13 Dec 1901 20:45:54 GMT to Tue, 19 Jan 2038 03:14:07 GMT. (These are the dates that correspond to the minimum and maximum values for a 32-bit signed integer.) Additionally, not all platforms support negative timestamps, therefore your date range may be limited to no earlier than the Unix epoch. This means that e.g. dates prior to Jan 1, 1970 will not work on Windows, some Linux distributions, and a few other operating systems. PHP 5.1.0 and newer versions overcome this limitation though. From MySQL manual @ http://dev.mysql.com/doc/refman/4.1/en/date-and-time-type-overview.html: The range is '1970-01-01 00:00:01' UTC to partway through the year 2037. TIMESTAMP values are stored as the number of seconds since the epoch ('1970-01-01 00:00:00' UTC). A TIMESTAMP cannot represent the value '1970-01-01 00:00:00' because that is equivalent to 0 seconds from the epoch and the value 0 is reserved for representing '-00-00 00:00:00', the “zero” TIMESTAMP value. HTH - Nuno -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Cannot convert value '0000-00-00 00:00:00' from column 4 to TIMESTAMP
I'm simply executing a SELECT query that used to work before, same database, everything the same except a higher version of the MySQL server. -Original Message- From: Nuno Oliveira [mailto:[EMAIL PROTECTED] Sent: Monday, 22 January 2007 7:33 PM To: mysql@lists.mysql.com Subject: Re: Cannot convert value '-00-00 00:00:00' from column 4 to TIMESTAMP The second major problem I am running into after the upgrade is the following error, which did not occur on Development. Error Executing Database Query. Cannot convert value '-00-00 00:00:00' from column 4 to TIMESTAMP. The error occurred on line 8. MySQL version is: 5.0.27 Thanks in advance for any help. I don't know what/how are you doing and I don't even know enough about the subject but: From PHP manual @ http://pt.php.net/manual/en/function.strtotime.php: Note: The valid range of a timestamp is typically from Fri, 13 Dec 1901 20:45:54 GMT to Tue, 19 Jan 2038 03:14:07 GMT. (These are the dates that correspond to the minimum and maximum values for a 32-bit signed integer.) Additionally, not all platforms support negative timestamps, therefore your date range may be limited to no earlier than the Unix epoch. This means that e.g. dates prior to Jan 1, 1970 will not work on Windows, some Linux distributions, and a few other operating systems. PHP 5.1.0 and newer versions overcome this limitation though. From MySQL manual @ http://dev.mysql.com/doc/refman/4.1/en/date-and-time-type-overview.html: The range is '1970-01-01 00:00:01' UTC to partway through the year 2037. TIMESTAMP values are stored as the number of seconds since the epoch ('1970-01-01 00:00:00' UTC). A TIMESTAMP cannot represent the value '1970-01-01 00:00:00' because that is equivalent to 0 seconds from the epoch and the value 0 is reserved for representing '-00-00 00:00:00', the zero TIMESTAMP value. HTH - Nuno -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Cannot convert value '0000-00-00 00:00:00' from column 4 to TIMESTAMP
I'm simply executing a SELECT query that used to work before, same database, everything the same except a higher version of the MySQL server. In that case you are probably facing some uncompatible issue between the versions you used. Maybe someone else is able to help you more that I :( Sorry -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Cannot convert value '0000-00-00 00:00:00' from column 4 to TIMESTAMP
This is because with version 4.1 and higher the format of timestamp changes to -00-00 00:00:00. We had this problem, so we had to add a few lines in the scripts that take this field and work with it -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Cannot convert value '0000-00-00 00:00:00' from column 4 to TIMESTAMP
Hi thanks for replying. I can't immediately see the difference between your sample and mine, except the single quotes are missing, is that it? Thanks in advance. -Original Message- From: tere [mailto:[EMAIL PROTECTED] Sent: Monday, 22 January 2007 9:12 PM To: mysql@lists.mysql.com Subject: RE: Cannot convert value '-00-00 00:00:00' from column 4 to TIMESTAMP This is because with version 4.1 and higher the format of timestamp changes to -00-00 00:00:00. We had this problem, so we had to add a few lines in the scripts that take this field and work with it -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Cannot convert value '0000-00-00 00:00:00' from column 4 to TIMESTAMP
The second major problem I am running into after the upgrade is the following error, which did not occur on Development. Error Executing Database Query. Cannot convert value '-00-00 00:00:00' from column 4 to TIMESTAMP. The error occurred on line 8. MySQL version is: 5.0.27 Thanks in advance for any help. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]