search for: my_argu

Displaying 1 result from an estimated 1 matches for "my_argu".

Did you mean: my_args
2005 Dec 15
2
HABTM being tricky
...ing from an XML with the same results - the first resulting correct relationships (99 records in artists_genres), while the second resulted in an artists_genres table containing 7 records - one for each genre. The way the records were inserted was with something like this: artist = Artist.new( my_arguments ) genre = Genre.find_by_name( my_genre_name ) unless genre genre = Genre.new( :name => my_genre_name ) end artist.genres << genre artist.save I _think_ I''m doing everything right, but if not I''m sure someone will let me know ;).. but anyway, has anyone run into a...