Hello,
I can pull 3 tables data into my program and read from all of them, i can update all 3 datasets but when it comes to updating the actual database i can only send the updates from the last dataset.
Imports System.Data
Dim con As New OleDb.OleDbConnection
Dim ds As New DataSet
Dim da As OleDb.OleDbDataAdapter
Dim sql As String
Public Sub OpenAllTables()
'CONNECTIONSTRING - THIS IS WHERE THE CONNECTION TAKES PLACE
con.ConnectionString = "PROVIDER=Microsoft.Jet.OLEDB.4.0;Data Source = C:\Users\Danny\Desktop\Financial Data\FBS.mdb"
con.Open()
sql = "SELECT * FROM tblIncome"
da = New OleDb.OleDbDataAdapter(sql, con)
da.Fill(ds, "Income")
sql = "SELECT * FROM tblSavings"
da = New OleDb.OleDbDataAdapter(sql, con)
da.Fill(ds, "Savings")
sql = "SELECT * FROM tblExpenditure"
da = New OleDb.OleDbDataAdapter(sql, con)
da.Fill(ds, "Expenditure")
con.Close()
End Sub
The above code is how i call the three tbls, the wierd thing is that if i switch the order (savings with expenditure) then savings will be allowed to get updated and not expenditure.
Any Ideas??