From: Thufir Date: 2009-09-20T18:27:41+09:00 Subject: Re: instead of MySql, use ActiveRecord or other ORM On Sun, 20 Sep 2009 18:14:07 +0900, Thufir wrote: [...] > Basically, how to I make the above more db independant with some form of > ORM? Well, I looked forever and only found the answer after posting: thufir@ARRAKIS:~/rb$ thufir@ARRAKIS:~/rb$ cat iterate.rb require 'rubygems' require 'active_record' require 'feed_tools' ActiveRecord::Base.establish_connection( :adapter => "mysql", :host => "127.0.0.1", :username => "ruby", :password => "password", :database => "rss2mysql") class Items < ActiveRecord::Base end claims = Items.find( :all) claims.each do |claim| puts claims.object_id end thufir@ARRAKIS:~/rb$ thanks to: http://www.rubyinside.com/advent2006/17-extendingar.html -Thufir