I have two tables, one called Profiles and one called Regions. The Profiles table has a table reference (list) to the Regions table.
On the front end, users complete a form to update their profile with the regions they are in.
In my API, I have an input that contains the values for the new regions they select on the form.
I've figured out how to merge the values from the form with the values in the table already, but I want to clear out the old values. I don't want to merge them together.
How do I clear out the old values and only add the new values?
Updating table reference list array
Answered
2 replies