Hi:

The weird thing is that not always do the same, I mean I always introduce that insert query, but not always inserts a wrong date, sometimes the date is correct.

Mikel


From: "Roger Baklund" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
CC: "Miguel Perez" <[EMAIL PROTECTED]>
Subject: Re: odd Date
Date: Fri, 20 Jun 2003 16:41:13 +0200

* Miguel Perez
> I have the following problem:
>
> When I insert a date in my table, and after do the insert I select the
> column date to see if the date is right but it displays the date like
> follows:
>
> 2019-06-20
>
> When the original insert is:
>
> 2003-06-19

You would get this result if you tried to insert the date as '19-06-2003':

mysql> use test;
Database changed
mysql> create table datetest (d date);
Query OK, 0 rows affected (0.12 sec)

mysql> insert into datetest set d='19-06-2003';
Query OK, 1 row affected (0.02 sec)

mysql> select * from datetest;
+------------+
| d          |
+------------+
| 2019-06-20 |
+------------+
1 row in set (0.03 sec)

> I looked into the manual to figure out how mysql works with date
> types, and I didn't find anything.

<URL: http://www.mysql.com/doc/en/Using_DATE.html >
<URL: http://www.mysql.com/doc/en/Date_and_time_types.html >
<URL: http://www.mysql.com/doc/en/Date_and_time_functions.html >

--
Roger

_________________________________________________________________
MSN Fotos: la forma más fácil de compartir e imprimir fotos. http://photos.msn.es/support/worldwide.aspx



-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]



Reply via email to