This is because dreamweaver has inserted all of the insert and update code into a single code block.
The best way to prevent this is to separate them into separate code blocks by adding:
?>
<?php
in between each. I've done that for you on the page. Now you should be able to update each of them individually.