From: "Tim.Teng" Date: 2007-09-13T16:26:12+09:00 Subject: Re: How to read values dynamically Hi, here is a instance for read values dynamically class Test A_HASH = {"key1"=>value1,"key2"=>value2} A_HASH.each_key do |key| module_eval <<-EOF def #{key} find :all,:conditions=>[" attribute = ?",Test::A_HASH[#{key}]] end EOF end end You see ,it really dynamical. Best Regards. Tim