List:General Discussion« Previous MessageNext Message »
From:Michael Widenius Date:September 17 1999 12:39am
Subject:Re: Saving dates as YYYYMMDD
View as plain text  
>>>>> "Martin" == Martin Ramsch <m.ramsch@stripped> writes:

Martin> On Wed, 1999-09-15 20:12:17 +0200, Christian Mack wrote:
>> "Daniel E. White" wrote:
Martin> [...]
>> > +------------+------------+---------------------+
>> > | date_field | time_field | datetime_field      |
>> > +------------+------------+---------------------+
>> > | 1999-09-14 | 20:49:01   | 1999-09-14 20:49:01 |
>> > | 1999-09-14 | 356:49:01  | 1999-09-14 20:49:01 |
>> > +------------+------------+---------------------+
Martin> [...]
>> > Anyone know what that 356 is ?  It sure is NOT Julian day.
Martin> [...]
>> The 365 are houres!
>> The TIME field has a valid range from '-838:59:59' to '838:59:59'
>> and it correctly uses 14 as days.
>> So it calculates 14 days + 20 h 49min 01 sec = 356 h 49 min 01 sec.
>> Months and years are skipped, because out of the valid TIME range.

Martin> At least for MySQL V3.22.19b this explanation can't be right, as my
Martin> own tests just seggest that it's a bug.

<cut>

Christian is right about the reason and Martin is right that this is
a bug.  It's now fixed for 3.23.4.

Regards,
Monty
Thread
Saving dates as YYYYMMDDClaudia M. Castaneda14 Sep
  • Re: Saving dates as YYYYMMDDMike Machado14 Sep
    • Re: Saving dates as YYYYMMDDMartin Ramsch14 Sep
  • Re: Saving dates as YYYYMMDDChristian Mack14 Sep
    • Re: Saving dates as YYYYMMDDDaniel E. White15 Sep
      • Re: Saving dates as YYYYMMDDMichael Widenius17 Sep
  • Re: Saving dates as YYYYMMDDChristian Mack15 Sep
    • Re: Saving dates as YYYYMMDDMartin Ramsch16 Sep
      • Re: Saving dates as YYYYMMDDMichael Widenius17 Sep