Subject Re: [firebird-support] Re: Date Extraction
Author Helen Borrie
At 02:54 AM 9/05/2006, John Craig wrote:
>--- Helen Borrie wrote:
> >
> > or DAY, YEAR..
> > The parts you can extract are
> > YEAR | YEARDAY| MONTH | DAY | WEEKDAY (from a DATE type)
> > and HOUR | MINUTE | SECOND (from a TIME type). You can extract any
> > of them from a TIMESTAMP type.
>Two follow-on questions:
>1. Are these functions (and similar ones I didn't know about ;-)
>documented in your book (The Firebird Book) that's available from the
>ibphoenix site?

Yes. There's an entire chapter on stuff you can do with date and time types.

>2. Is there a slick way to get a textual representation of the month
>and weekday (e.g. 'January' rather than 1)?

Only with a UDF, e.g. DOW in FBUDF. FreeUDFLib also has some
functions that return English strings from date types. Appendix 1 of
the book is a summary of all the UDF syntaxes.