Migrations This guide is based on guides.rubyonrails.org/migrations.html Overview Migrations make it easy to alter your database’s schema in a systematic manner. They make it easier to coordinate with other developers and make sure that all developers are using the same database schema. Migrations are optional, you don’t have to use them. You can always just create the necessary database structure
Cheat Sheet Open a database require 'rubygems' require 'sequel' DB = Sequel.sqlite('my_blog.db') DB = Sequel.connect('postgres://user:password@localhost/my_db') DB = Sequel.postgres('my_db', :user => 'user', :password => 'password', :host => 'localhost') DB = Sequel.ado('mydb') Open an SQLite memory database Without a filename argument, the sqlite adapter will setup a new sqlite database in memory
Ruby Sequel is a lightweight database toolkit for Ruby.Sequel provides thread safety, connection pooling and a concise DSL for constructing database queries and table schemas. Sequel also includes a lightweight but comprehensive ORM layer for mapping records to Ruby objects and handling associated records. Sequel supports advanced database features such as prepared statements, bound variables, mas
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く