I have 2 tables. For example “Fruits” and “Food” When I create a new entry for the Fruits table with the corresponding model, how do I save objects and attributes of this one to the other table called All?
Or easier: How to update another table when saving a new entry?
i need something like “update value where id=x”
You have to do something like this :
Just so you know, you can also do the following if you don’t want to write the “private” !