Using an active record, how can I return the results for a model if they do not exist in certain respects elsewhere. For example, let's say I have a Recipe model that belongs to categories (via the category_recipes join table).
So basically I have a Rake task that looks at each recipe and its description and tries to paste it into a category, but the task takes a lot of time and I will need to run it on a regular basis, so I only want to run it if the Recipe question wasnβt already classified, and I would prefer not to add an extra column, for example categorized , so I believe that there is a way to get only Recipes that do not exist in the join table. Any thoughts?
JP Silvashy
source share