4 step process

ALTER TABLE to add a new Date column

Populate the new field with the date portion of the DATETIME

Drop the DATETIME column

Rename the DATE column with the name of the original field.

=C=

*
* Cal Evans
* Journeyman Programmer
* Techno-Mage
* http://www.calevans.com
*


-----Original Message-----
From: Joćo Paulo Vasconcellos [mailto:[EMAIL PROTECTED]]
Sent: Friday, May 03, 2002 1:43 PM
To: [EMAIL PROTECTED]
Subject: (Maybe) Silly question


Hello everybody,

  i was thinking about my database, and I found that the guy who planned it
before me created a field to hold the date people registered with the site.
The field is a DATETIME, but the time portion is never used!

  So, I began to wonder if I could resize the field to DATE, but I am not
sure if the DATE part will be the same after the change. Anybody here did
this before ?






[ Hello filter, I can speak SQL :) ]

--
Joćo Paulo Vasconcellos
Gerente de Tecnologia - NetCard
Tel. 21 3852-9008 Ramal 31
[EMAIL PROTECTED]

---------------------------------------------------------------------
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