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.7.34 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.33 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.32 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.31 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.30 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.29 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.28 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.27 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.26 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.25 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.24 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.23 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.22 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.21 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.20 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.19 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.18 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.17 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.16 db/migrate/20110131211919_add_sessions_table.rb
zuora_connect-1.7.15 db/migrate/20110131211919_add_sessions_table.rb