× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



On Tue, Sep 9, 2014 at 10:38 AM, Jeff Young <jyoung0950@xxxxxxxxx> wrote:
Using SQL, how do I convert a numeric value of a database field in ISO date
format (ccyymmdd) to a DATE data type for comparison?
I need to select all records with a date that is equal to a value input by
the user.

I think we all agree that the "right" way to do dates is with date
fields. However, if all you need is to check for equality, probably
the fastest thing to do is to convert your input to numeric ISO and do
a direct comparison with that.

And in your case, even if you had to check for earlier-than,
later-than, or between, you could still use the numeric ISO dates
as-is (this would not be the case for MDY, USA, or EUR numeric-field
dates).

That said, it is probably still worth having iDate. :)

John Y.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.