Sha256: 42497982a1d692e3f6e6c308792ee96aab2e115202443e246c0e916805794aea

Contents?: true

Size: 372 Bytes

Versions: 295

Compression:

Stored size: 372 Bytes

Contents

class AddSessionsTable < ActiveRecord::Migration
  def change
    if !ActiveRecord::Base.connection.table_exists?('sessions')
      create_table :sessions do |t|
        t.string :session_id, :null => false
        t.text :data
        t.timestamps
      end
      add_index :sessions, :session_id, :unique => true
      add_index :sessions, :updated_at
    end
  end
end

Version data entries

295 entries across 295 versions & 4 rubygems

Version Path
zuora_connect-1.4.7 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.4.6 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.4.5 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.4.4 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.4.3 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.4.2 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.4.1 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.4.0 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.3.9 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.4.0c db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.4.0b db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.4.0a db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.3.8.1 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.3.8 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.3.7 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.3.6 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.3.5 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.3.4 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.3.3 db/migrate/20170131211919_add_sessions_table.rb
zuora_connect-1.3.2 db/migrate/20110131211919_add_sessions_table.rb