Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Different result same query on FB5.0.2.1583 vs FB2.5.6.26967 #8365

Closed
OlegMatveevFB opened this issue Dec 26, 2024 · 1 comment
Closed

Different result same query on FB5.0.2.1583 vs FB2.5.6.26967 #8365

OlegMatveevFB opened this issue Dec 26, 2024 · 1 comment

Comments

@OlegMatveevFB
Copy link

SELECT prc.ID_NEW, t.ID
FROM P12 prc
LEFT JOIN T1 t ON t.id=prc.ID_NEW

FB5.0.2.1583
ID_NEW ID
2 < null >

FB2.5.6.26967
ID_NEW ID
2 2

Metadata:

CREATE TABLE T1 (ID INTEGER);

CREATE SEQUENCE GEN_T1_ID;

SET TERM ^ ;

CREATE TRIGGER T1_Bi FOR T1
ACTIVE BEFORE INSERT POSITION 0
AS
BEGIN
IF (NEW.Id IS NULL) THEN
NEW.Id = GEN_ID(Gen_T1_Id,1);
END^

CREATE PROCEDURE P12
RETURNS (ID_NEW INTEGER)
AS
BEGIN
ID_NEW = GEN_ID(Gen_T1_Id, 1);
INSERT INTO T1 (id) VALUES (:ID_NEW);
SUSPEND;
END^

SET TERM ; ^

COMMIT;

@aafemt
Copy link
Contributor

aafemt commented Dec 26, 2024

As designed: Firebird 5 has cursor stability so query cannot see own changes.

@OlegMatveevFB OlegMatveevFB closed this as not planned Won't fix, can't repro, duplicate, stale Jan 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants