-
May 24th, 2018, 01:25 PM
#1
Thread Starter
Frenzied Member
How best to update table definition in ADO.NET DataSet Designer
Using database first I created a table. I drag and drop it from the Server Explorer onto the designer and it defines my table. Now I decide to add or change a column. As it is now, the only way I can think to do it is to delete the table, save and drag-n-drop it again. I was hoping I could right click someplace and find a command "Update table definition". Is there an elegant way to update the table definition in the designer?
-
May 24th, 2018, 07:46 PM
#2
Re: How best to update table definition in ADO.NET DataSet Designer
I haven't really used typed DataSets for a while but, when I did, I used the Data Sources window to generate a Data Source and that would create DataTables and table adapters for each selected table. I'm not sure whether dragging from the Server Explorer generates a Data Source or not. Check the Data Sources window and see whether it has. If it has, there's a button on the toolbar at the top of the Data Sources window that will refresh the Data Source from the database. That should enable you to add missing tables and columns. Just note that it will not remove tables or columns that are not in the database any more. Deletes must be done manually, because it doesn't want to delete anything by mistake that you may have added manually.
-
May 24th, 2018, 07:47 PM
#3
Thread Starter
Frenzied Member
Re: How best to update table definition in ADO.NET DataSet Designer
-
May 26th, 2018, 04:11 PM
#4
Thread Starter
Frenzied Member
Re: How best to update table definition in ADO.NET DataSet Designer
I finally had time to try this and it worked. If I change the name of a column, I need to delete it in the designer and add it back by running the wizard. Thanks.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|