ok, so i have a database with 2 related tables (one-to-many). What i'm trying to do is to connect to the database, fill 2 DataTable objects, and add them to a DataSet object. Then I would need to bind each column in the DataTables to a text box on the form, and allow the user to update the database after modification. They will also need to be able to add/remove a record to/from the db.
However, I'm not quite sure how to do all of this. I'll write some specific questions below:
- will i need a new DataAdpater for each table?
- Will visual basic automatically enforce referential integrity between the 2 related tables in the database? if not, how do i do that?
- I read somewhere that it's easier to update a database with a OleDbCommandBuilder object, does anyone know of any examples of that?
Also, if i'm going about this completely wrong, feel free to suggest a better (or more accurate) way of doing it.
However, I'm not quite sure how to do all of this. I'll write some specific questions below:
- will i need a new DataAdpater for each table?
- Will visual basic automatically enforce referential integrity between the 2 related tables in the database? if not, how do i do that?
- I read somewhere that it's easier to update a database with a OleDbCommandBuilder object, does anyone know of any examples of that?
Also, if i'm going about this completely wrong, feel free to suggest a better (or more accurate) way of doing it.
Last edited: