SQLite doesn't repoint table aliases in partial index conditions on table rename which breaks the documented table alteration procedure. Thanks Pēteris Caune for the report. Backport of 34decdebf157b6f05836009cc1967f74ee541fdf from master