Subject Re: [firebird-support] using extract on null values
Author Milan Babuskov
Dmitry Yemanov wrote:
>>Is there a way, to get null or another default value for YOB in this case?

FB 1.5:

> 1) CASE
> WHEN A.BIRTHDATE IS NULL THEN NULL
> ELSE EXTRACT(YEAR FROM A.BIRTHDATE)
> END

FB 2.0:

> 2) FB 2.0 returns NULL in your case

FB 1.0:

You can use F_YEAR UDF from rfunc UDF library:

http://rfunc.sourceforge.net


--
Milan Babuskov
http://swoes.blogspot.com/
http://www.flamerobin.org