Skip to content

Commit

Permalink
Updated Postgresql-hstore (markdown)
Browse files Browse the repository at this point in the history
  • Loading branch information
braidn committed Apr 14, 2015
1 parent 6ea15f6 commit b8bcf95
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions Postgresql-hstore.md
Original file line number Diff line number Diff line change
@@ -1 +1,14 @@
# Postgres Hstore Extension

## Notes

* All values stored a strings
* Access is done like hashes `something[:fun]`

### Requirements

* These columns need to be indexed and can be done so in two ways:
* GIN: indexes are three types faster to search, but they take more time to index. They also take more disk space. Use it when you have more than 100K unique terms.
* GiST: indexes are slower than GIN indexes, but they’re faster to update. Use it when you have up to 100K unique terms
* When using Rails you can just use the `add_index` syntax
* ex: `add_index :users, :preferences, using: :gin`

0 comments on commit b8bcf95

Please sign in to comment.