Ticket Hash: | 490a4b723562429807f13842ab2536997cca2491 | ||
Title: | "WHERE 0" on the first element of a UNION causes an assertion fault | ||
Status: | Fixed | Type: | Code_Defect |
Severity: | Important | Priority: | Immediate |
Subsystem: | Unknown | Resolution: | Fixed |
Last Modified: |
2013-07-09 03:04:50 11.99 years ago |
Created: |
2013-07-09 02:24:58 11.99 years ago |
Version Found In: | 3.7.17 |
User Comments: | ||||
drh added on 2013-07-09 02:24:58:
(text/x-fossil-wiki)
The following SQL script results in an assertion fault: <blockquote><verbatim> CREATE TABLE abc(a,b,c); INSERT INTO abc VALUES(1,2,3); CREATE TABLE def(d,e,f); INSERT INTO def VALUES(3,4,5); SELECT * FROM abc WHERE 0 UNION SELECT * FROM def; </verbatim></blockquote> This bug appears to have been in the code essentially forever. Incorrect VDBE code has been generated since version 3.3.7 (circa 2006) and prior to that the code generator segfaults. |