Subject | Parameterised procedure with a dynamic array. |
---|---|
Author | sergiogarciaruso |
Post date | 2012-02-15T16:44:42Z |
Hi. I would like to parameterize a procedure with a dynamic array. Is there such functionality in Firebird? And if so, how is the syntax? I have FB v2.5 SS installed. I want to do something like this:
SET TERM ^ ;
CREATE OR ALTER PROCEDURE MyProc(
p_inputparam INTEGER,
p_dyn_array My dynamic array ¿HOW TO DO THAT?
)
AS
DECLARE i INT;
DECLARE Total INT;
BEGIN
Total = SIZEOF(p_dyn_array); --Retrive the number of elements of my dynamic array
i = 0;
WHILE (i < Total) DO BEGIN
i = i + 1;
-- Do something
END
END^
SET TERM ; ^
Thanks in advance.
Sergio (sorry my english)
SET TERM ^ ;
CREATE OR ALTER PROCEDURE MyProc(
p_inputparam INTEGER,
p_dyn_array My dynamic array ¿HOW TO DO THAT?
)
AS
DECLARE i INT;
DECLARE Total INT;
BEGIN
Total = SIZEOF(p_dyn_array); --Retrive the number of elements of my dynamic array
i = 0;
WHILE (i < Total) DO BEGIN
i = i + 1;
-- Do something
END
END^
SET TERM ; ^
Thanks in advance.
Sergio (sorry my english)