Hello folks. I''m new in Ruby also ROR. I installed oracle intant client and test it it works fine. Now I wanna connect to oracle db. But its got some error. like this *custom_require.rb:36:in `require'': cannot load such file -- oci8 (LoadError)* my code is here. require ''oci8'' oci = OCI8.new(''user'',''pass'',''ip:port/sid'') oci.exec(''select * from table'') do |record| puts record.join('','') end Pls help me. What''s wrong ? Regards. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CAPs6WSebTp9RM0CBvoQEYheXA3HkUp3%2B04Piom0FQTtDDARDKw%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Hi Tsolmon, Have u installed ruby-oci8 gem package Regards Mehdi On 8/29/13, Tsolmon Narantsogt <mnts26-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hello folks. > > I''m new in Ruby also ROR. > I installed oracle intant client and test it it works fine. Now I wanna > connect to oracle db. But its got some error. like this > *custom_require.rb:36:in `require'': cannot load such file -- oci8 > (LoadError)* > > my code is here. > > require ''oci8'' > oci = OCI8.new(''user'',''pass'',''ip:port/sid'') > oci.exec(''select * from table'') do |record| > puts record.join('','') > end > > Pls help me. What''s wrong ? > > Regards. > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To view this discussion on the web visit > https://groups.google.com/d/msgid/rubyonrails-talk/CAPs6WSebTp9RM0CBvoQEYheXA3HkUp3%2B04Piom0FQTtDDARDKw%40mail.gmail.com. > For more options, visit https://groups.google.com/groups/opt_out. >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CABRbsVk5GCMZx%2BQLTCYD2j5AoQ%2Bigg5gwq5%2BcQDVGZ3a%3D5szgw%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Yes i installed ruby-oci8 from source. like this linux: ruby setup.rb config -- --with-instant-client *then * *mnts26@mnts26:~/Downloads/ROR OCI8/ruby-oci8-2.0.4$ make* ruby -w setup.rb config setup.rb:278: warning: assigned but unused variable - vname setup.rb:278: warning: assigned but unused variable - desc setup.rb:278: warning: assigned but unused variable - default2 setup.rb:109: Use RbConfig instead of obsolete and deprecated Config. ---> lib ---> lib/dbd <--- lib/dbd ---> lib/oci8 <--- lib/oci8 <--- lib ---> ext ---> ext/oci8 /home/mnts26/.rvm/rubies/ruby-1.9.3-p448/bin/ruby /home/mnts26/Downloads/ROR OCI8/ruby-oci8-2.0.4/ext/oci8/extconf.rb setup.rb:476: warning: Insecure world writable dir /opt/oracle in PATH, mode 040777 /home/mnts26/.rvm/rubies/ruby-1.9.3-p448/bin/ruby: No such file or directory -- /home/mnts26/Downloads/ROR (LoadError) ''system /home/mnts26/.rvm/rubies/ruby-1.9.3-p448/bin/ruby /home/mnts26/Downloads/ROR OCI8/ruby-oci8-2.0.4/ext/oci8/extconf.rb '' failed Try ''ruby setup.rb --help'' for detailed usage. make: *** [config.save] Error 1 I got those lines. Regards On Thu, Aug 29, 2013 at 4:38 PM, Khizer Mehdi <kmehdi85-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi Tsolmon, > > Have u installed ruby-oci8 gem package > > Regards > Mehdi > > On 8/29/13, Tsolmon Narantsogt <mnts26-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > Hello folks. > > > > I''m new in Ruby also ROR. > > I installed oracle intant client and test it it works fine. Now I wanna > > connect to oracle db. But its got some error. like this > > *custom_require.rb:36:in `require'': cannot load such file -- oci8 > > (LoadError)* > > > > my code is here. > > > > require ''oci8'' > > oci = OCI8.new(''user'',''pass'',''ip:port/sid'') > > oci.exec(''select * from table'') do |record| > > puts record.join('','') > > end > > > > Pls help me. What''s wrong ? > > > > Regards. > > > > -- > > You received this message because you are subscribed to the Google Groups > > "Ruby on Rails: Talk" group. > > To unsubscribe from this group and stop receiving emails from it, send an > > email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > > To view this discussion on the web visit > > > https://groups.google.com/d/msgid/rubyonrails-talk/CAPs6WSebTp9RM0CBvoQEYheXA3HkUp3%2B04Piom0FQTtDDARDKw%40mail.gmail.com > . > > For more options, visit https://groups.google.com/groups/opt_out. > > > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To view this discussion on the web visit > https://groups.google.com/d/msgid/rubyonrails-talk/CABRbsVk5GCMZx%2BQLTCYD2j5AoQ%2Bigg5gwq5%2BcQDVGZ3a%3D5szgw%40mail.gmail.com > . > For more options, visit https://groups.google.com/groups/opt_out. >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CAPs6WSdg4N8JeJs99m5NfkYOZoUSpHb7u1NMHoRtwCGC4yUDmA%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Installation failed due to error For installing that ruby-oci8 gem u need 1. instantclient-basic 2. instantclient-sdk 3. u need to export LD_LIBRARY_PATH of that path 4. then run bundle install Regards Mehdi On 8/29/13, Tsolmon Narantsogt <mnts26-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Yes i installed ruby-oci8 from source. > like this > linux: > ruby setup.rb config -- --with-instant-client > *then * > > *mnts26@mnts26:~/Downloads/ROR OCI8/ruby-oci8-2.0.4$ make* > ruby -w setup.rb config > setup.rb:278: warning: assigned but unused variable - vname > setup.rb:278: warning: assigned but unused variable - desc > setup.rb:278: warning: assigned but unused variable - default2 > setup.rb:109: Use RbConfig instead of obsolete and deprecated Config. > ---> lib > ---> lib/dbd > <--- lib/dbd > ---> lib/oci8 > <--- lib/oci8 > <--- lib > ---> ext > ---> ext/oci8 > /home/mnts26/.rvm/rubies/ruby-1.9.3-p448/bin/ruby > /home/mnts26/Downloads/ROR OCI8/ruby-oci8-2.0.4/ext/oci8/extconf.rb > setup.rb:476: warning: Insecure world writable dir /opt/oracle in PATH, > mode 040777 > /home/mnts26/.rvm/rubies/ruby-1.9.3-p448/bin/ruby: No such file or > directory -- /home/mnts26/Downloads/ROR (LoadError) > ''system /home/mnts26/.rvm/rubies/ruby-1.9.3-p448/bin/ruby > /home/mnts26/Downloads/ROR OCI8/ruby-oci8-2.0.4/ext/oci8/extconf.rb '' > failed > Try ''ruby setup.rb --help'' for detailed usage. > make: *** [config.save] Error 1 > > I got those lines. > > Regards > > > > > On Thu, Aug 29, 2013 at 4:38 PM, Khizer Mehdi <kmehdi85-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > >> Hi Tsolmon, >> >> Have u installed ruby-oci8 gem package >> >> Regards >> Mehdi >> >> On 8/29/13, Tsolmon Narantsogt <mnts26-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: >> > Hello folks. >> > >> > I''m new in Ruby also ROR. >> > I installed oracle intant client and test it it works fine. Now I wanna >> > connect to oracle db. But its got some error. like this >> > *custom_require.rb:36:in `require'': cannot load such file -- oci8 >> > (LoadError)* >> > >> > my code is here. >> > >> > require ''oci8'' >> > oci = OCI8.new(''user'',''pass'',''ip:port/sid'') >> > oci.exec(''select * from table'') do |record| >> > puts record.join('','') >> > end >> > >> > Pls help me. What''s wrong ? >> > >> > Regards. >> > >> > -- >> > You received this message because you are subscribed to the Google >> > Groups >> > "Ruby on Rails: Talk" group. >> > To unsubscribe from this group and stop receiving emails from it, send >> > an >> > email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org >> > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org >> > To view this discussion on the web visit >> > >> https://groups.google.com/d/msgid/rubyonrails-talk/CAPs6WSebTp9RM0CBvoQEYheXA3HkUp3%2B04Piom0FQTtDDARDKw%40mail.gmail.com >> . >> > For more options, visit https://groups.google.com/groups/opt_out. >> > >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Ruby on Rails: Talk" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org >> To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/rubyonrails-talk/CABRbsVk5GCMZx%2BQLTCYD2j5AoQ%2Bigg5gwq5%2BcQDVGZ3a%3D5szgw%40mail.gmail.com >> . >> For more options, visit https://groups.google.com/groups/opt_out. >> > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To view this discussion on the web visit > https://groups.google.com/d/msgid/rubyonrails-talk/CAPs6WSdg4N8JeJs99m5NfkYOZoUSpHb7u1NMHoRtwCGC4yUDmA%40mail.gmail.com. > For more options, visit https://groups.google.com/groups/opt_out. >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CABRbsV%3DgebsYGFtq7S0wmFHYc6mcE2K_hgZXOba2%3DhsQv0V7NA%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.