|Ruby9i Project Summary | JimCain.US|
Ruby9i is a Ruby library that provides access to Oracle9i using the Oracle Call Interface. There are two APIs: the C extension in ruby9i.so and the DBI::DBD-compatible interface defined in Ruby9i.rb.
A simple query using the ruby9i.so API looks like this:
I'm sure you can come up with some DBI examples on your own.
After being laid off in June 2003, I took a look at Ruby for the
first time. My first impression was, "Wow! This is the language I
would've written." I wanted to learn more about it, and since I had a
lot of time on my hands, I decided to write a Ruby interface to
Oracle9i. I had already done something
similar for C++ a few years back, and it was a great learning
experience. So, the day after reading Ruby's documentation for the
first time, I dove right in.
Now in January 2004, I am newly employed as an Oracle9i DBA, and I
have been wanting to use Ruby for some automation and scripting
tasks—perfect motivation to return to the Ruby9i project. Besides,
I'd like Ruby9i to be stable and complete just in time to be enhanced
Statement#fetchreturns Ruby9i-specific types so that Oracle features may be accessed through them. The
#to_builtinmethod is supported by all Ruby9i types so that native Ruby types may be easily retrieved. (Note that data loss will occur in cases where Ruby's precision does not match Oracle's.)
A user guide is available. It was developed in
XML using the DocBook DTD and XSL stylesheet, and I added some minor
things to customize the appearance for Ruby. This customization is not
yet complete, however. It's still missing support for things like
blocks. Even so, you're welcome to download a tarball of the complete
documentation set, including the
XML and XSL, or just the HTML.
The Ruby9i Library is licensed under the Artistic License.
I would appreciate any feedback you might have, especially since this is my first attempt at Ruby.
Last modified January 26, 2004. Send comments to firstname.lastname@example.org.