title: Postgres hstore: GIN vs GiST index performance
body: <p>I have to decide whether to use GIN or GiST indexing for an hstore column.</p>
  
  <p>The <a href="http://www.postgresql.org/docs/current/static/textsearch-indexes.html" rel="noreferrer">Postgres docs</a> state:</p>
  
  <ul>
  <li>GIN index lookups are about three times faster than GiST</li>
  <li>GIN indexes take about three times longer to build than GiST</li>
  <li>GIN indexes are about ten times slower to update than GiST</li>
  <li>GIN indexes are two-to-three times larger than GiST</li>
  </ul>
  
  <p>The way I interpret it, use GIN if you need to query a lot, use GiST if you need to update a lot.</p>
  
  <p>In this <a href="http://thebuild.com/presentations/pg-as-nosql-pgday-fosdem-2013.pdf" rel="noreferrer">test</a>, all of the three disadvantages of GIN over GiST mentioned above are confirmed. However, other than suggested in the Postgres docs, the advantage of GIN over GiST (faster lookup) is very small. Slide 53 shows that in the test GIN was only 2% to 3% faster as opposed to 200% to 300% suggested in the Postgres docs.</p>
  
  <p>Which source of information is more reliable and why?</p>