Subject Re: [firebird-support] Version Control of Stored Procedures/Triggers
Author Lele Gaifax
robertgilland wrote:
> Is there anyway of storing/setting a version number of a Stored
> Procedure/Trigger?
>
> So we can know if a Stored Procedure/Trigger is out of date?

I use something like the following: I have one-file-per-SP containing
the implementation, and the whole thing is kept under SVN.

Each source looks like

SET TERM ^;

CREATE OR ALTER PROCEDURE some_sp_name_here AS
BEGIN
EXIT;
END
^

UPDATE rdb$procedures
SET rdb$description = '$Id$'
WHERE rdb$procedure_name = 'SOME_SP_NAME_HERE'
^

This is nice because most tools are able to show that field side-by-side
with the SP name, in their browser.

FB 2.x has a cleaner syntax to say the same.

hth,
ciao, lele.