You may find it easier to store the date as a timestamp and convert it on
the fly, depending on what you're using to get the info from the database.

In PHP, you'd need something like 

        $date = mktime(0,0,0,$month,$day,$year);

where $month, $day and $year hold the date you're dealing with (i.e.
$month=11, $day=10, $year=1974 gives you my DoB, 10th Nov 1974, in case you
want to remember it so you can buy me a present :-) Store $date in your
database, and you have a standard UNIX timestamp that can be read by pretty
much anything, displayed however you want, and sorted on.

There are probably other ways of dealing with this that are as/more
efficient, but this works for me.


HTH
Jon



-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]
Sent: 23 January 2001 12:16
To: [EMAIL PROTECTED]
Subject: Sorting a date



Hi,

I would like to sort, when displaying, an "European Date" with mysql. 

Anyone can give me some hints ?

The date format looks so like : 

        01.02.2001 
        03.12.2000
        22.11.2000

and is stored in a simple field text  

(first FEB 2001)

Thanks 
GPo



---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail
<[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to