title: Removing table from schema.rb
body: <p>I had a Location model in my app, but then I went a step back with Git, when I didn't create the model yet, then after quite a while working on another branch I realized that the model had gone nowhere, and it is still in my schema. I tried to get rid of it but it still pops out of nowhere, although there are no add location migration files in my app. What is the best way to get rid of it and clean up my schema.rb?</p>
  
  <p>UPDATE 1</p>
  
  <p>Running </p>
  
  <p>rails destroy model location</p>
  
  <p>Gives me </p>
  
  <pre><code>  invoke  active_record
    remove    /Users/denis/Desktop/migration/templates/create_table_migration.rb
    remove    app/models/location.rb
    invoke    test_unit
    remove      test/models/location_test.rb
    remove      test/fixtures/locations.yml
  </code></pre>
  
  <p>And I can run it for the indefinite amounts, it will always give the same result</p>
  
  <p>Running this migration:</p>
  
  <pre><code>class DropLocationsTable &lt; ActiveRecord::Migration
    def self.up
      drop_table :locations
    end
  end
  </code></pre>
  
  <p>Gives 0 result, after rake db:migrate the Locations appear in my schema.rb again</p>
  
  <p>UPDATE 2</p>
  
  <pre><code>rails db
  SQLite version 3.7.12 2012-04-03 19:43:07
  Enter ".help" for instructions
  Enter SQL statements terminated with a ";"
  sqlite&gt; SELECT * FROM locations;
  sqlite&gt; 
  </code></pre>