public
Description: I eat URLs. RAWRRRRR!
Clone URL: git://github.com/bottlecaplabs/zombieurl.git
zombieurl / db / migrate / 003_add_index_on_website_url.rb
100644 12 lines (8 sloc) 0.244 kb
1
2
3
4
5
6
7
8
9
10
11
12
class AddIndexOnWebsiteUrl < ActiveRecord::Migration
  def self.up
    
    execute "CREATE INDEX website_url_index ON links ((substring(website_url, 0, 200)));"
    
  end
 
  def self.down
    execute "DROP INDEX website_url_index;"
  end
end