How can I update, add and delete records of a Data object whos recordset is retrieved by an SQL statement? Do I have to first make the record source point to an existing table, then add the record, and finally re-issue the SQL statement?
Printable View
How can I update, add and delete records of a Data object whos recordset is retrieved by an SQL statement? Do I have to first make the record source point to an existing table, then add the record, and finally re-issue the SQL statement?
Using DAO, you have a couple of ways of doing this. You can code everything in SQL and pass it thru a recordset/execute or you can use the DAO methods.
For updates, I genereally use a recordset to retrieve the data and "executes" to update. I mostly use "execute" for delete and "recordset" for inserts.