[Ironruby-core] Newwer to Ironruby/ruby

Jimmy Schementi Jimmy.Schementi at microsoft.com
Wed Jan 13 03:16:05 EST 2010

> I noticed your update to:
> http://ironruby.net/Documentation/Real_Ruby_Applications/Rails#database
> also, I had to add this:
> in environment.rb as well so it would be added to the load path to get it to
> work correctly.  

That's what these lines are for:
$:.unshift "#{IRONRUBY_DBI_PATH}/src/lib"
$:.unshift "#{SQLSERVER_ADAPTER_PATH}/lib"

The code to add to environment.rb that's in the link there is all that is needed.
Adding the lines you added should have no effect, especially the first one
as the correct dbi.rb won't be found in ironruby-dbi.

> Plus, I needed the deprecated gem which irooruby-dbi requires. 

Step #2 of Setup says to install the "deprecated" gem.

> Might be worth mentioning that the user should also set their
> correct username and password.

Where? In the database.yml file, I suggested to use integrated security, which
doesn't require putting your username and password.

It'd be great to bundle all this in a ironruby-rails gem to do this automatically.
Also, ironruby-dbi really should just depend on the dbi gem itself, and be
renamed to ironruby-dbd, which just adds the mssql dbd extension. It should also
take a dependency on the depreciated gem so it doesn't need to be installed separately.

More information about the Ironruby-core mailing list