After successfully installing the ruby-0ci8 gem and the oracle_enhanced adapter gem I get the following error when I try to fire up my rails project server:
=> Booting WEBrick
=> Rails 3.0.3 application starting in development on http://0.0.0.0:3000
=> Call with -d to detach
=> Ctrl-C to shutdown server
Exiting
/Library/Ruby/Gems/1.8/gems/activerecord-oracle_enhanced-adapter-1.3.2/lib/active_record/connection_adapters/oracle_enhanced_oci_connection.rb:7:
ERROR: ActiveRecord oracle_enhanced adapter could not load ruby-oci8 library.
Please install ruby-oci8 gem. (LoadError)
Both the enhanded adapter and ruby-oci8 gem show up in my gem list. Both are present in my Gemfile. Why can't the adapter find the oci8 library?
Some specs on setup I'm running:
- Mac Snow Leopard (10.6.8)
- Ruby 1.8.7 (2009-06-12 patchlevel 174) [i686-darwin10.8.0]
- Rails 3.0.3
- ruby-oci8 (2.0.4) [gem]
- activerecord-oracle_enhanced-adapter (1.3.2) [gem]
I've looked at this post: Rails 3.0.3 - Oracle_enhanced doesn't work. But it's not helping. Anyone else run into this?
==============================
Answer
I got it figured out. In the end i had an incorrect file structure in /usr/local/oracle/instantclient_10_2/ where I had stored the files for my oracle instant client. That is what was causing all the issues. Basically I had nested a second instantclient_10_2 directory inside the first and I had my .bash_profile looking in the first directory and not the one below it.