Hello Everyone ! Please help me with the following set of code:
Dim daTest as New SqlDataAdapter
Dim dsTest as New DataSet
Dim cbTest as SqlCommandBuilder
Dim dRowTest as DataRow
Dim conx as New SqlConnection(conxString)
conx.Open()
daTest.SelectCommand = New SqlCommand("Select * From Table1", conx)
cbTest = New SqlCommandBuilder(daTest)
daTest.FillSchema(dsTest, SchemaType.Source, "Table1")
daTest.Fill(dsTest, "Table1")
daTest.SelectCommand = New SqlCommand("Select * From Table2", conx)
daTest.FillSchema(dsTest, SchemaType.Source, "Table2")
daTest.Fill(dsTest, "Table2")
daTest.SelectCommand = New SqlCommand("Select * From Table3", conx)
daTest.FillSchema(dsTest, SchemaType.Source, "Table3")
daTest.Fill(dsTest, "Table3")
dRowTest = dsTest.Tables("Table1").Rows.Find(Value)
dRowTest.BeginEdit()
dRowTes.Item("FieldName") = 1
dRowTes.EndEdit()
daTest.Update(dsTest,"Table1")
When I execute that code , it says that "Missing the DataColumn 'Table2.FieldName' in the DataTable 'Table1' for the SourceColumn 'Table2.FieldName' ".
Where I did mistake? Please point me out! or DataAdapter can't update DataTable Partially?