Cách hoạt động khi thêm 1 row dữ liệu đến database

string queryinsert = @"INSERT INTO NHANVIEN(HOTEN,GIOITINH,NGAYSINH,DIACHI,DIENTHOAI,MATRINHDO) VALUES(@HOTEN,@GIOITINH,@NGAYSINH,@DIACHI,@DIENTHOAI,@MATRINHDO)";
SqlCommand cmdinsert = new SqlCommand(queryinsert, con);

  
cmdinsert.Parameters.Add("@hoten", SqlDbType.NVarChar, 50, "hoten");
cmdinsert.Parameters.Add("@gioitinh", SqlDbType.Bit, 2, "gioitinh");//2 GIÁ TRỊ
cmdinsert.Parameters.Add("@ngaysinh", SqlDbType.Date, 10, "ngaysinh");
cmdinsert.Parameters.Add("@diachi", SqlDbType.NVarChar, 100, "diachi");
cmdinsert.Parameters.Add("@dienthoai", SqlDbType.NVarChar, 20, "dienthoai");
cmdinsert.Parameters.Add("@matrinhdo", SqlDbType.Int, 5, "matrinhdo");//5 CHỮ SỐ

DA.InsertCommand = cmdinsert;

làm thế nào nó biết lấy giá trị dataset để truyền vào database trong khi đoạn code ở đây ko đề cập gì đến dataset cả

// đoạn code update sau khi thêm dòng vào datatable của dataset lên database
if (con.State == ConnectionState.Closed)
{
    con.Open();
}
DA.Update(DL_nhanvien, "table_nhanvien");
MessageBox.Show("LƯU THÀNH CÔNG !", "THÔNG BÁO");
con.Close();

có ai có thể chạy đoạn code này 1 cách theo thứ tự từ lúc đã thêm -> update lên database đc ko ?

83% thành viên diễn đàn không hỏi bài tập, còn bạn thì sao?