G
Guest
www.asp.net website introduced a way to develop 3-tier websites (
http://www.asp.net/learn/dataaccess/default.aspx?tabid=63 )
The question is, how to modify datasets without deleting and creating
datatables?
Let's imagine we've a table in SQL Server named "Person",
it includes: ID,FirstName,LastName fields.
we create a dataset in App_Code folder, and configure it to show Person
table and generate Insert,Update and Delete code by its wizard.
Then we write methods in BLL to show/add/modify records of Person table.
Well, imagine we had a bad design and now we decide to add Telephone field
to Person table,
what is the best way to update dataset and re-write BLL methods?
Deleting the dataset and re-creating it is a bad idea, because we may have
many queries in the table adapter attached to dataset.
http://www.asp.net/learn/dataaccess/default.aspx?tabid=63 )
The question is, how to modify datasets without deleting and creating
datatables?
Let's imagine we've a table in SQL Server named "Person",
it includes: ID,FirstName,LastName fields.
we create a dataset in App_Code folder, and configure it to show Person
table and generate Insert,Update and Delete code by its wizard.
Then we write methods in BLL to show/add/modify records of Person table.
Well, imagine we had a bad design and now we decide to add Telephone field
to Person table,
what is the best way to update dataset and re-write BLL methods?
Deleting the dataset and re-creating it is a bad idea, because we may have
many queries in the table adapter attached to dataset.