Rails on PostgreSQL : Rails, PostgreSQL, and database drivers /2009/09/04/rails-postgresql-and-database-drivers?format=rss en-us 40 <h3>If you like Ruby on Rails, you'll love Rails on PostgreSQL!</h3> Comment on Rails, PostgreSQL, and database drivers by alex@alexkane.net <p>Great website! Is the new pg driver much faster?</p> Fri, 04 Sep 2009 21:55:37 -0500 urn:uuid:da6ea2fd-bb4c-428e-a23c-f163b0f39286 http://railsonpostgresql.com/2009/09/04/rails-postgresql-and-database-drivers#comment-1 Comment on Rails, PostgreSQL, and database drivers by Tom Copeland <p>@alex, Thanks! I haven&#8217;t seen any benchmarks&#8230; but it&#8217;s definitely the way to go.</p> Fri, 04 Sep 2009 22:27:42 -0500 urn:uuid:b1dcaab2-e1bd-41fe-bffa-ed182eb125b8 http://railsonpostgresql.com/2009/09/04/rails-postgresql-and-database-drivers#comment-2 Comment on Rails, PostgreSQL, and database drivers by Darren Boyd <p>On OSX (Leopard), this is the process I used to get the native gem to build&#8230;</p> <pre><code>sudo su - export ARCHFLAGS='-arch i386' export PATH=/opt/local/lib/postgresql83/bin:$PATH gem install pg &lt;control + d to log out of super user&gt; </code></pre> <p>Note that the postgres bin path is specific to my installation.</p> Fri, 18 Sep 2009 10:15:38 -0500 urn:uuid:aee0ab57-e4b7-4b65-bd7e-4003f40232af http://railsonpostgresql.com/2009/09/04/rails-postgresql-and-database-drivers#comment-8 Comment on Rails, PostgreSQL, and database drivers by Wayne E. Seguin <p>You do not need to install gems as root. If the reason is &#8220;because then the command shows up&#8221; then add the user&#8217;s gem directory to your path:</p> <pre><code>PATH=$PATH:~/.gem/ruby/1.8/bin</code></pre> <p>You can even set this exclusively:</p> <pre><code>GEM_HOME=~/.gem/ruby/1.8</code></pre> <p>For the purposes of pg gem, in order to cover both bases (both 32 &amp; 64 bit compiled postgres installs) on OSX:</p> <pre><code>ARCHFLAGS="-arch i386 -arch x86_64"</code></pre> <p>Ensure that your path has psql in it as noted above. Change /opt/local/lib/postgresql83/bin to wherever you have pg_config located. For me this is:</p> <pre><code>PATH=$PATH:/usr/local/postgresql/bin ; export PATH</code></pre> <p>Then install the gem.</p> <pre><code>gem install pg</code></pre> <p>This non-root technique is especially useful when you have multiple ruby versions installed and are actively switching/using all of them ( I use rvm for this <a href="http://rvm.beginrescueend.com/" rel="nofollow">http://rvm.beginrescueend.com/</a> )</p> <p>w00t for Postgres!</p> Wed, 30 Sep 2009 10:44:44 -0500 urn:uuid:402f5398-a661-4f85-9874-aaeb6304f893 http://railsonpostgresql.com/2009/09/04/rails-postgresql-and-database-drivers#comment-9 Comment on Rails, PostgreSQL, and database drivers by Tom Copeland <p>@wayne, true&#8230; I guess that most of the time when I install a gem, though, I want it to be available to all user accounts on the box. But you&#8217;re right, another possibility is to just install it to your home directory.</p> Wed, 30 Sep 2009 11:46:14 -0500 urn:uuid:00f7f7d2-e613-4ce8-b4ed-f62f462c8c21 http://railsonpostgresql.com/2009/09/04/rails-postgresql-and-database-drivers#comment-12