title: What happens to Triggers/Indexes when i rename/create/insert/drop a table in SQLite?
body: <p>What happens to Triggers/Indexes when i rename/drop a table SQLite?</p>
  
  <p>I'm running and upgrade script where i add a column to a table, so i d the following:</p>
  
  <pre><code>ALTER TABLE [Entry] RENAME TO [Entry_temp];
  CREATE TABLE [Entry] (
      [EntryID] integer PRIMARY KEY AUTOINCREMENT NOT NULL,
      ...
  )
  INSERT INTO [Entry] 
   (...)
    SELECT ...
    FROM [Entry_temp];
  DROP TABLE [Entry_temp];
  </code></pre>
  
  <p>The Entry table had a trigger and an index</p>
  
  <pre><code>-- these were created before    
  CREATE TRIGGER Entry_Version_Update AFTER UPDATE ON [Entry]
    BEGIN
      UPDATE [Entry] SET [Version] = [Version] + 1
    WHERE [EntryID] = new.[EntryID];
    END;
  
  CREATE INDEX ix_Entry_ClientID ON [Entry] ([ClientID]);
  </code></pre>
  
  <p>Do i have to drop them before the update and create a new one after? Or can i just leave them?</p>