Forum: Ruby on Rails Postgres-pr interface not found

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Blake M. (Guest)
on 2007-04-19 01:17
I've installed the postgres-pr gem, and it is found using gem list

In my active record source, inside the postgresql_adapter.rb file, I've
changed line 7 from:
require_library_or_gem 'postgres' unless

require_library_or_gem 'postgres-pr' unless
self.class.const_defined?(:PGconn) try and force it to use the postgres-pr interface, but I get the
following error when loading a page:
no such file to load -- postgres-pr

Why can't it find that gem?

OSX 10.4.X - app server
Winblows XP - db server
Blake M. (Guest)
on 2007-04-19 01:33
> Why can't it find that gem?
I seem to have gotten around it by putting the full path to the gem, and
dropping the "-pr" from the gem (since there is no postgres-pr.rb file,
but there is a postgres.rb file in the postgres-pr folder).

New code is:
unless self.class.const_defined?(:PGconn)

Interesting that it can't find a gem based on the name that lists when
you execute "gem list".  But it's more likely indicative of my noob
understanding of the require_library_or_gem function.
This topic is locked and can not be replied to.