View Ticket
Ticket Hash: fd76310a5e843e074a30ed98b859dd0be11d0276
Title: TEXT value interpreted as column name in an index with empty list in an IN expression
Status: Closed Type: Code_Defect
Severity: Critical Priority: Immediate
Subsystem: Code_Generator Resolution: Fixed
Last Modified: 2019-06-10 15:35:32
Version Found In:
User Comments:
mrigger added on 2019-06-10 00:14:49: (text/x-fossil-wiki)
Consider the following case:

CREATE INDEX i0 ON t0('1' IN ());
ALTER TABLE t0 RENAME TO t1; -- error in index i0: no such column: 1

It seems that the empty list on the right side of the IN operator causes '1' to be interpreted as a column name during the ALTER TABLE statement, but not when the index is created, thus resulting in an error when renaming the table.