On 10/27/05, Kerry <[EMAIL PROTECTED]> wrote:
> dont know about best practice, but to ensure date portability I dont use
> date fields in the DB, I use varchar fields and put ISO dates in them e.g.
>
> 20051027T161420
>
> Then if needed, I convert to proper dates once the value is out of the DB.
> Since I know the string will alway be in the same format, I can use string
> functions e.g. mid() to pull the data out and create a date -
> createdate(left(mydate,4),mid(mydate,5,2) e.t.c.

Uhm, that way you lose the ability to use some db features (e.g. date
comparison, max, etc.), don't you?

Thanks.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:222454
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to