With datatsets, especially typed datasets in VS.NET 2005, it is simple.
You have a table adapter (or data adapter) that has an update method. This update method takes care of updating the database with cnay changes (inserts, updates, deletes).
I use GetMultiAsDataTable to get a data table of records. I modify them in the UI. I want to send this modified datatable back to the database. If any records were modifed, added, or deleted, the LLBLGen DAO would take care of sending the proper command to the database to sync it.
This is simple to do in VS 2005 with a typed dataset. Example shown:
To fill a typed dataset (lutblZone)
Dim ta As New dsZoneTableAdapters.lutblZoneTableAdapter()
Dim ds As New dsZone
ta.Fill(ds.lutblZone)
To update this back into the database I simply do the following:
This will send any update, insert, delete queries it needs to send to the database
Dim ta As New dsZoneTableAdapters.lutblZoneTableAdapter()
ta.Update(ugZoneMachine.DataSource)
This is so simple. All I need to do is create a types dataset in my project - all the SQL code required to get and change data is sone behind the scenes.
How can I do this in LLBLGen Pro? I know how to get the data table, I just do not know how to send updates from the data table back to the database easily. I do not want to use the LLBLGen Entity or Collection classes for this purpose.