2011-03-01ãã1ã¶æéã®è¨äºä¸è¦§
STI æã« find_by_sql ã§è¿ãã¤ã³ã¹ã¿ã³ã¹ã®ã¯ã©ã¹ã«ã¤ãã¦èª¿ã¹ã¦ã¿ã¾ãããactiverecord-1.13.2 㨠activerecord-2.3.11 ã§æåã調ã¹ã¾ããã activerecord-1.13.2/lib/active_record/base.rb 427 # Works like find(:all), but requires a complete SQL sâ¦
ãã¹ãã¯æ£ããã¨æãã®ã«ãä½æ ãè½ã¡ãç¾è±¡ã«ãªãã¾ããã調ã¹ã¦ããããMySQLã®MyISAMãã¼ãã«ã§ use_transactional_fixtures ã true ã«ãã¦ãããã¨ãåå ã§ãããã¨ãåããã¾ããã activerecord-2.3.10/lib/active_record/fixtures.rb use_transactiâ¦
Rubyã®cgiã«ã¯ããªãã©ã¤ã³ã¢ã¼ãããããã³ãã³ãã©ã¤ã³ããç°¡åã«cgiã試ããã¨ãåºæ¥ã¾ãã ãªãã©ã¤ã³ã¢ã¼ãã使ã£ã¦ã¿ã ã¾ãã¯ãä¸è¨ã®è¨è¿°ããããã¡ã¤ã«ãä½æãã¾ãããã¡ã¤ã«å㯠hoge.rb ã¨ãã¾ãã require 'cgi' cgi = CGI.new p cgi.params ãªâ¦
Rails ã® active_support/core_ext/string/inflections.rb 㧠Ruby ã® String ãæ¡å¼µãã㦠constantize ã使ãã¦ä¾¿å©ã§ãã % script/console Loading development environment (Rails 2.3.11) >> "Hash".constantize => Hash >> :Hash.constantize NoMethoâ¦