FirebirdSQL / firebird

Firebird server, client and tools
https://www.firebirdsql.org/
1.19k stars 204 forks source link

AV when preparing a query with IN list that contains both literals and sub-query #8087

Closed hvlad closed 4 weeks ago

hvlad commented 1 month ago

Test case:

SELECT *
  FROM RDB$RELATIONS R
 WHERE R.RDB$RELATION_ID IN (1, (SELECT D.RDB$RELATION_ID FROM RDB$DATABASE D))
hmoffatt commented 3 days ago

I have this query crashing Firebird 5.0.0 when running embedded (I haven't tried with a server yet), on both Windows x86 and x64 and Linux x64.

select X.*
from A_INTREC X
where X.LEVEL_DEF_NUM in (14088,14089,11826,11920,12012,12097,12174,12246,12310,12365,12407,12440,12460,12476,12490,12501,12511,12518,12523) 
order by 1

This has gone away with the latest 5.0.1 snapshot, but I can't find an exact issue filed here that matches my case. Do you think it is this bug?