You can change this to write into a temp table, and then "flush" the results at the end, even check uniqueness over the temp table first.
It the record does not already exist, a new record will be added. " Else SQL = "UPDATE tbl Contact" SQL = SQL " SET Name = '" & Request("Name") & "', Email= '" & Request("Email") & "', Phone= '" & Request.
Ideally, adding new records and changing existing records are tasks you'd accomplish using the appropriate application interface—not through the SQL command line.
However, adding and updating records is a common part of development and quality assurance testing.
In the previous topic, Fetch Records we learnt how to retrieve the Form data and store it in a form variable.
This form variable, also called collection variable, contains the retrieved form data.