Subject | Re: [firebird-support] DATEADD doesn't work with WEEK |
---|---|
Author | Richard Wesley |
Post date | 2008-11-18T17:45:51Z |
On 18 Nov 2008, at 07:26, skoczian wrote:
DATEADD(DAY, %2*7, CAST(%3 AS TIMESTAMP))
in our code for FB 2.1.
HTH
________________________________________________________
Richard Wesley Senior Software Developer Tableau
Software
Visit: http://www.trytableau.com/now.html
> The following is taken straight from the Firebird Book, Supplement 2,Don't think it does. We have
> Appendix I Function Summary, p. 249:
>
> SQL> SELECT DATEADD(WEEK, 1, DATE 'YESTERDAY') FROM RDB$DATABASE;;
>
> Result (in ISQL, Firebird 2.1, Windows XP):
>
> DATEADD
> ===========
> Statement failed, SQLCODE = -833
> expression evaluation not supported
>
> DAY, MONTH, YEAR work as expected. And in the notes for the DATEADD
> function WEEK is missing. So I'm not quite sure if it really should
> work.
DATEADD(DAY, %2*7, CAST(%3 AS TIMESTAMP))
in our code for FB 2.1.
HTH
________________________________________________________
Richard Wesley Senior Software Developer Tableau
Software
Visit: http://www.trytableau.com/now.html