title: PG::UndefinedObject: ERROR: type "hstore" does not exist but it does
body: <p>First of all, this may look like a duplicate of: </p>
  
  <p><a href="https://stackoverflow.com/questions/19467481/postgres-hstore-exists-and-doesnt-exist-at-same-time">postgres hstore exists and doesn&#39;t exist at same time</a></p>
  
  <p>but it is not. While I am getting the same error message in the circumstance. When checking to see if hstore is installed on the DB, we can see that it is:</p>
  
  <pre><code>./psql -d photographerio_development -c '\dx'
                         List of installed extensions
    Name   | Version |   Schema   |                   Description                    
  ---------+---------+------------+--------------------------------------------------
   hstore  | 1.2     | hstore     | data type for storing sets of (key, value) pairs
   plpgsql | 1.0     | pg_catalog | PL/pgSQL procedural language
  </code></pre>
  
  <p>and it is too on the template_1 DB.</p>
  
  <p>So, when I try to run the migration to add the hstore, I get the <code>PG::Error: ERROR:  extension "hstore" already exists</code> and when I comment out this migration, on the next one, which requires the hstore, it says <code>PG::UndefinedObject: ERROR:  type "hstore" does not exist</code> which is a bit of a paradox.</p>
  
  <p>It is a Rails 4.0.1 app with postgresql 9 and I have hstore working on a few other projects running on this machine.</p>