Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   Ruby (http://www.velocityreviews.com/forums/f66-ruby.html)
-   -   ruby problem connecting to oracle using oci8 (http://www.velocityreviews.com/forums/t858778-ruby-problem-connecting-to-oracle-using-oci8.html)

Dheeraj Gambhir 07-27-2009 11:11 AM

ruby problem connecting to oracle using oci8
 
Hi,

My code is:

require 'dbi'



def dataVerification()
puts "Begin Conn!"
ora_connect = DBI.connect("DBI:OCI8:orcl;Data
Source=mlbd;UserId=mlbread;Password=mlbread")
oracleAccountInfoValues = getDBValue(ora_connect, "select invoice_id
from bam_order.ec_invoice where order_id =139920")
ora_connect.disconnect
ora_Id = oracleAccountInfoValues[0]
puts ora_Id

end
dataVerification()


When i run this, it gives me :

C:/ruby/lib/ruby/site_ruby/1.8/dbi.rb:329:in `load_driver': Unable to
load drive
r 'OCI8' (DBI::InterfaceError)
from C:/ruby/lib/ruby/site_ruby/1.8/dbi.rb:227:in
`_get_full_driver'
from C:/ruby/lib/ruby/site_ruby/1.8/dbi.rb:213:in `connect'
from testcon.rb:8:in `dataVerification'
from testcon.rb:15

I am using:
-Ruby 1.8.6
-Oracle 9i Enterprise Management

Please let me know if any body have any idea that why this error is
coming?

Regards
D G
--
Posted via http://www.ruby-forum.com/.



All times are GMT. The time now is 08:06 PM.

Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57