Subject | Re: [ib-support] Date format returned |
---|---|
Author | Svein Erling Tysvaer |
Post date | 2002-09-20T11:41:06Z |
Hi Derek!
I didn't see any reply to this question on the list, hence this late answer.
Your question does not quite make sense (I believe). Dates are stored as
the number of days since a given date (some date in 1858 I believe). The
engine may interpret a few different formats, like DD.MM.YYYY OR MM/DD/YYYY
(I think the third one is YYYY-MM-DD or similar). In general, however, I
find that it returns a Date data type and that it is up to me as a
programmer or the user as specified in his/her ShortDateFormat global
variable how things are viewed.
So my answer would be that you ought to think of what is returned from
Firebird as a Date type, not a string (use .AsDateTime rather than .AsString).
HTH,
Set
At 10:04 18.09.2002 -0700, you wrote:
I didn't see any reply to this question on the list, hence this late answer.
Your question does not quite make sense (I believe). Dates are stored as
the number of days since a given date (some date in 1858 I believe). The
engine may interpret a few different formats, like DD.MM.YYYY OR MM/DD/YYYY
(I think the third one is YYYY-MM-DD or similar). In general, however, I
find that it returns a Date data type and that it is up to me as a
programmer or the user as specified in his/her ShortDateFormat global
variable how things are viewed.
So my answer would be that you ought to think of what is returned from
Firebird as a Date type, not a string (use .AsDateTime rather than .AsString).
HTH,
Set
At 10:04 18.09.2002 -0700, you wrote:
>Hello All,
>Just a quick question. Currently my Firebird
>installation returns Date data types in this format:
>YYYYMMDD.
>Is there any quick and dirty way to return the more
>natural(for American users):
>MMDDYYYY