I have two tables. Let say headers and details. On headers_controller.rb I have
has_many :details On details_controller.rb I have belongs_to :header I have in my model for header (just for testing): def list @headers = Headers.sort( "headers.kind ASC") end So when i run after loading the proper data a header.details.size it returns me the number of details for the selected header. But when I try to display header.details.size in a list view for the headers I get an arror saying "Unrecognized constant Header::Detail" I try to get this in the list with: <%= header.details.size %> What am I doing wrong? -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.