search for: associated_object

Displaying 2 results from an estimated 2 matches for "associated_object".

2005 Mar 08
19
find_by_sql ON STEROID possible?
...magine we want to fetch every book and every associated object.....down to the author university with rails we can do Books.find_all and then after in the code book.publisher , book.authors and then author.university.... this is to me the real beauty of active record that allows us to write object.associated_object(s). this is the real beauty that allows us to forget SQL while concentrating on model construction....and that lower development times A LOT!!!!! when there is 10 books everything is OK !!!! there''s only 10 books inside a development DB But when there''s 500 books, in a productio...
2008 Jan 25
1
model creating a model?
hi all, is it possible for a model to create an object (of which it has many), when it is first created? i''m trying to have something like Image -hm-> ImageThumbs where the first ImageThumb is created when the Image object is saved, and any validation errors from ImageThumb.validation are passed back to the original object/page template. any thoughts on this? thanks for reading. --