Subject Re: Insert Dates
Author donjules2k
I have decided to go with usein "dd-MMM-yyyy" as that seems to always
work perfectly. What is the best format for entering a time? (Both on
it's own and as part of a date, hence Timestamp)

Thanks

Giulio


--- In firebird-support@yahoogroups.com, "Svein Erling"
<svein.erling.tysvaer@k...> wrote:
> dd/mm/yyyy is not amongst the string formats Firebird can accept for
> dates. You can choose between dd.mm.yyyy, mm/dd/yyyy, dd-mmm-yyyy (I
> think, with mmm being English abbreviation for month) and one or two
> more formats. Or you can use a parameter
> INSERT INTO MY_TABLE (DATEFIELD) VALUES(:MyDate);
> and assign it using whatever date format is defined at the client
> (using parameters the date is passed, not a string).
>
> HTH,
> Set
> -Wonder how many persons there will be at the Fulda conference that
> aren't members of the Firebird Foundation, simply because no-one has
> told them they can join at http://www.firebirdsql.org/ff/foundation?
>
>
> --- In firebird-support@yahoogroups.com, "donjules2k" wrote:
> > INSERT INTO MY_TABLE (DATEFIELD) VALUES('06/05/2004');
> >
> > Now, this is in dd/mm/yyyy format, hence 6th may 2004. When I insert
> > it, it and then do a select in IBO Console, i see '05/06/2004'. So i
> > think, oh ok the DB is showing me dates in mm/dd/yyy format, no
> problem.
> >
> > However, I go and select this date using .Net provider and I get the
> > date 5th Junes 2004, i.e. i has actually swapped my day and month
> > around and not just showing a different format.
> >
> > Question: How do I get FB to understand that my dates are in
> > dd/mm/yyyy format and should only be so.
> >
> > FYI:
> >
> > Running FB 1.5, Win XP Pro, local settings set to UK time and
> > localisation (hence dd/mm/yyy)
> >
> > Any ideas?
> >
> > Thanks
> >
> > Giulio