You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
create or alter procedure p1 (N integer) returns (R integer)
as
begin
R = N;
suspend;
end^
commit^
create or alter procedure p2 returns (S varchar(100))
as
declare I integer;
begin
I = 0;
while (I < 3) do
begin
I = I + 1;
SELECT
(SELECT
coalesce(:S, '') || ' ' || :I || '=' || (SELECT R from P1(:I))
FROM RDB$DATABASE
)
FROM RDB$DATABASE
INTO S;
end
suspend;
end^
commit^
select * from p2^
---------------
1=1 2=1 3=1
The procedure is not re-called in the subsequent queries.
Submitted by: @abzalov
Votes: 4
create or alter procedure p1 (N integer) returns (R integer)
as
begin
R = N;
suspend;
end^
commit^
create or alter procedure p2 returns (S varchar(100))
as
declare I integer;
begin
I = 0;
while (I < 3) do
begin
I = I + 1;
SELECT
(SELECT
coalesce(:S, '') || ' ' || :I || '=' || (SELECT R from P1(:I))
FROM RDB$DATABASE
)
FROM RDB$DATABASE
INTO S;
end
suspend;
end^
commit^
select * from p2^
---------------
1=1 2=1 3=1
The procedure is not re-called in the subsequent queries.
Commits: 2f80120
The text was updated successfully, but these errors were encountered: