Subject Procedure parameter mismatch
Author nols_smit
Hi,

I'm using FB 1.5.3.4870

When I try to compile the procedure code (displayed below), I get the
following error message (caused by the Execute statement):

fmCompile.trCompile:
Invalid token.invalid request BLR at offset 454.
parameter mismatch for procedure GET_SACS_BY_NO.

Any ideas what's wrong?

Regards,

Nols Smit

/* ------------- procedure code ---------------- */
CREATE PROCEDURE GET_SACS_BY_NO (
PSACSNO INTEGER)
RETURNS (
ID INTEGER,
UQSACSNO INTEGER,
LITHONAME CHAR (60) CHARACTER SET WIN1252,
LITHORANK CHAR (5) CHARACTER SET WIN1252)
AS
declare variable SACSNO integer;
declare variable CNT integer;
BEGIN
/* Procedure body */
Select UQ_Sacs_No from V_Sacs where Parent_UQ_Sacs_No = :PSACSNO
into :SACSNO;

Select count(UQ_Sacs_No) from V_Sacs where
Parent_UQ_Sacs_No = :PSACSNO into :CNT;

if (cnt = 0) then
suspend;


For Select ID, UQ_Sacs_No, Litho_Name, Litho_Rank_Abbr from V_Sacs
where
Parent_UQ_Sacs_No = :PSACSNO
into :ID, :UQSACSNO, :LITHONAME, :LITHORANK
do
begin
Execute procedure GET_SACS_BY_NO :UQSACSNO;
end

SUSPEND;
END