Binding to joined tables
Many times it is necessary to bind to a datatable which is made up of multiple database tables. Most databases are normalized. In Visual Studio 2005 there was a particular technique to do this. Write your join statements in stored procedures, and create a table adapter within the dataset designer to use these stored procedures for update/delete and so forth.
With the advent of LINQ to SQL, there is a new way. First, create your objects, and then bind directly to a LINQ query. Note however that when binding to a LINQ query, the information is read-only. If you want a read-write binding to multiple database tables, a table adapter wired up to stored procedures for SELECT, INSERT, UPDATE, and DELETE commands is still the best way to accomplish this.
December 9th, 2008 at 8:52 pm
save to my Bookmarks )
April 25th, 2009 at 8:40 am
People should read this.
June 15th, 2009 at 2:02 am
Hi, very nice post. I have been wonder'n bout this issue,so thanks for posting
July 12th, 2009 at 8:59 pm
Rather interesting. Has few times re-read for this purpose to remember. Thanks for interesting article. Waiting for trackback