when using multiple forms on the same page, you'll need to use the button pressed to trigger so that the behavior only triggers on that button
make sure to always use unique names for the submit buttons to prevent a button from another page triggering an insert or update.