List:General Discussion« Previous MessageNext Message »
From:Paul DuBois Date:December 27 2002 3:08am
Subject:Re: Is this a MySQL error?
View as plain text  
At 11:47 +0200 12/25/02, Octavian Rasnita wrote:
>Hi all,
>
>I gave the following command in the default MySQL client:
>
>select from_days(365);
>
>The result is 0000-00-00 instead of 0001-00-00.
>
>If I gave the following command:
>
>select from_days(366);
>
>It gives the result 0001-01-01.
>
>If I give numbers less than 356, the result is 0 for the year, the month,
>and the day.
>
>Something's wrong I guess.

Take a look at this section of the manual:

http://www.mysql.com/doc/en/Date_and_time_functions.html

TO_DAYS() and FROM_DAYS() are intended only for dates as of the
beginning of the year 1582.

>
>Help!
>
>Thank you.
>
>Teddy,
>Teddy's Center: http://teddy.fcc.ro/
>Email: orasnita@stripped

sql, query
Thread
Is this a MySQL error?Octavian Rasnita25 Dec
  • Re: Is this a MySQL error?Benjamin Pflugmann25 Dec
  • Re: Is this a MySQL error?Paul DuBois27 Dec