Fastest way to set a field value in a given table

  • Thread starter Thread starter Ralph Wiggum
  • Start date Start date
R

Ralph Wiggum

I have some vb6 ado code that needs to be upgraded to .Net:

Set rs = CreateObject("ADODB.Recordset")
rs.Open "SELECT fieldname FROM tablename WHERE id=" & anyId, oConnection
rs(fieldname).value = anyValue
rs.close

The operation will be repeated many times, so performance is crucial. I've heard that DataTables are slow - what would be the best .Net approach here? OleDbCommand.ExecuteNonQuery(sql_update_statement)?

It's an Access database.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top