I have a form view which people use to update a record in the database. However initially the record will not exist, and all fields will show their default values. The first time the submit button is clicked, the record should be created in the database. Subsequent submits should update the existing record. The record is identified by it's primary key, which is passed to be page via Request.QueryString.
Does ASP.net provide a simple way of doing this, or do I need to roll my own implementation of the insert/update logic?