Mid From PDF ADO.NET ADO.NET

Use the DataAdapter's Update() method to push the changes back to the database.?

Example:

SqlDataAdapter adapter = new SqlDataAdapter("SELECT * FROM

Customers", connection);

SqlCommandBuilder commandBuilder = new SqlCommandBuilder(adapter);

// Automatically generates insert, update, delete commands

Follow:

DataSet dataset = new DataSet();

adapter.Fill(dataset, "Customers");

// Modify data in the DataSet

dataset.Tables["Customers"].Rows[0]["CustomerName"] = "New Name";

// Update the database with the modified data

adapter.Update(dataset, "Customers");

More from ADO.NET Core Tutorial

All questions for this course
Toolliyo Assistant
Ask about tutorials, ebooks, training, pricing, mentor services, and support. I use public site content only—not admin or internal tools.

care@toolliyo.com

Need callback? Share your details