diff options
author | yuuji.yaginuma <yuuji.yaginuma@gmail.com> | 2014-12-07 08:54:41 +0900 |
---|---|---|
committer | yuuji.yaginuma <yuuji.yaginuma@gmail.com> | 2014-12-07 08:54:41 +0900 |
commit | 42abc9d35b436283ea62e824a4ccefbe99c8c524 (patch) | |
tree | 4982afb019eeafeabbd392c52f3a9061ad57f0be /guides | |
parent | 01c3b92ac3e75eb5165e87e6b0ec05b5d8b73fa9 (diff) | |
download | rails-42abc9d35b436283ea62e824a4ccefbe99c8c524.tar.gz rails-42abc9d35b436283ea62e824a4ccefbe99c8c524.tar.bz2 rails-42abc9d35b436283ea62e824a4ccefbe99c8c524.zip |
[ci skip] add `enable_extension` to PostgreSQL hstore example
Diffstat (limited to 'guides')
-rw-r--r-- | guides/source/active_record_postgresql.md | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/guides/source/active_record_postgresql.md b/guides/source/active_record_postgresql.md index a2681a80e9..446be1c6d1 100644 --- a/guides/source/active_record_postgresql.md +++ b/guides/source/active_record_postgresql.md @@ -83,9 +83,12 @@ Book.where("array_length(ratings, 1) >= 3") * [type definition](http://www.postgresql.org/docs/9.3/static/hstore.html) +NOTE: you need to enable the `hstore` extension to use hstore. + ```ruby # db/migrate/20131009135255_create_profiles.rb ActiveRecord::Schema.define do + enable_extension 'hstore' unless extension_enabled?('hstore') create_table :profiles do |t| t.hstore 'settings' end |