I am a newbie to rails.
I posted but some of my code was cut off so here it is in parts.
For clarity though
I have a citations model and authors model with a author_cites model as a co-joining model
the author_cites model has the foreign keys of author_id and citation_id so I cannot insert into author_cites without first creating a citation
A citation can have many authors though so I need to store the author_id's in a ruby array and iterate over them after the citation is created.
While iterating over them I need to put or create author_cites for each value in the array with the citation id.
Last edited by jjliang (2013-05-03 02:34:52)