LoadError (no such file to load -- pg), OS X, Rails 3, Ruby 1.9.2, Postgres

Running OS X 10.6.4, wanted to work with the latest stuff, built Ruby
1.9.2 , installed rails 3.0.0 & pg 0.9.0 using gem, the simplest
example rails app gives me this whenever I try to access anything
(except plain HTML in public):

Started GET “/” for 127.0.0.1 at 2010-10-13 13:58:35 -0600

LoadError (no such file to load – pg):

…Followed by messages about rending error templates…

The which command shows that the path is right, ruby & rails & gem are
all found in /usr/local/lib.

Also, first thing I did after the install was create a small
standalone data import script. It requires rubygems and active_record,
and connects to the database and selects and inserts data (using
active record subclasses) just fine.

Besides rails & pg, the only other thing I’ve installed is the rb-
appscript gem.

Do you have “gem ‘pg’” on your Gemfile?

On 10/14/10 4:09 AM, Scott R. wrote:

…Followed by messages about rending error templates…
Besides rails & pg, the only other thing I’ve installed is the rb-
appscript gem.


Erol F.
http://github.com/Erol
http://twitter.com/erolfornoles
http://ph.linkedin.com/in/erolfornoles

On Oct 14, 2010, at 3:04 AM, Erol F. wrote:

Do you have “gem ‘pg’” on your Gemfile?

Ah, that was the problem. I was following a tutorial which did not
mention this new aspect of Rails 3 configuration.

Thanks much :wink:


Scott R.
[email protected]
http://www.elevated-dev.com/
(303) 722-0567 voice

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs