Selectable store procedure return inserted values - join not working in FB3
---------------------------------------------------------------------------
Key: CORE-6449
URL: http://tracker.firebirdsql.org/browse/CORE-6449
Project: Firebird Core
Issue Type: Bug
Affects Versions: 3.0.6
Reporter: Tomas Beran
I have stored procedure where I insert data to table and returning primary key
of inserted data.
When I write select * from PROCEDURE P left outer join TABLE T on T.PK = P.PK
then in Firebird 3.0.6 T is null, but in 2.5 T containg inserted data
When I create sql query in the same transaction to TABLE T - data is returned
example:
set term ^;
create table TEST_TABLE (
PKID integer,
TEXT varchar(10),
constraint TEST_TABLE_PKID primary key (PKID))^
create or alter procedure TEST_PROCEDURE (text varchar(10))
returns (PKID integer)
as
begin
select coalesce (max(PKID), 0) + 1
from TEST_TABLE
into :pkid;
insert into TEST_TABLE (PKID, TEXT) values (:pkid, :text);
suspend;
end
^
set term ;^
this query in FB 3.0.6 return null but in 2.5.9 return Hi
select T.TEXT
from TEST_PROCEDURE('Hi') P
left outer join TEST_TABLE T on T.PKID = P.PKID;
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://tracker.firebirdsql.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
Firebird-Devel mailing list, web interface at
https://lists.sourceforge.net/lists/listinfo/firebird-devel