I have a form with 6 fields (combination of dropdown menus and textboxes).
I populate the dropdowns from database tables. I have a loop that creates a
new row for the 6 fields in the form, so a user can insert as many records as needed (6 fields equal 1 record).

When a user submits the form, I use a loop to iterate through each row and
insert the records into the database.

I would like the user to be able to retrieve the fields they inserted, make
changes or add additional records and update.

Is there a way to re-populate the fields with the records that the user
submitted to the database, have the ability to change all the information
just like a user was inserting a new record (only they are editing a current record) and also be able to add to rows for inserting new records?

The fields are related to another database table. So, these records are
actually details of a master table (1 to many relationship). Each master
record has many detail records. So, I want the user to be able to edit
their detail records or add new detail records.

It is easy enough to create a sql query for all the detail records and bind
to the page. But, I need for example, to retrieve the value that was
inserted from a dropdown menu and still include the original values from the
dropdown if the user wants to change it.

Also, if the user views their current details, but only wants to add new
detail records, then the previously inserted records aren't re-inserted, but
only the new records are added.

I hope my post made sense. I'm not sure how to create this type of functionality on a form? If it is possible? Any suggestions on how to accomplish this?

Thanks for any help.