Firebird News

Tuesday, July 15, 2008

To use UDF modules in ubuntu/linux

You must put full path to the UDF module when you declare the function
in my case
/usr/lib/firebird/2.1/UDF

otherwise you will get something like
"Invalid token. invalid request BLR at offset 63. function SUBSTR is not defined. module name or entrypoint could not be found."


--FBUDF_API int isLeapYear(const ISC_TIMESTAMP* v);
declare external function isLeapYear
timestamp
returns int by value
entry_point 'isLeapYear' module_name '/usr/lib/firebird/2.1/UDF/fbudf.so';
then it worked

select isLeapYear(hire_date) from EMPLOYEE


Post a Comment