2007-09-23から1日間の記事一覧
前置き:もしかしてOracle限定かも。時間ができたらMySQLでも試してみます。 以下のmodelがあるとします。 class User ActiveRecord::Base belongs_to :role end class Role ActiveRecord::Base has_many :users end 例えばroles.levelが3以上の人数を数えた…
前置き:もしかしてOracle限定かも。時間ができたらMySQLでも試してみます。 以下のmodelがあるとします。 class User ActiveRecord::Base belongs_to :role end class Role ActiveRecord::Base has_many :users end 例えばroles.levelが3以上の人数を数えた…