C# work with linq to sql
-
I have a C#.net 2010 web form application that I need to add two tables to the database. This application uses linq to sql. Can you tell me if I want to add these two new tables to the sql server 2008 r2 database, do I 1. Need to remove the original .dbml file and recreate the .dbml file? 2. I would think I can just add two tables to the database and somehow refresh the existing .dbml file. If this possible? Whatever your answer is to the question, can you tell me how to solve this problem?
-
I have a C#.net 2010 web form application that I need to add two tables to the database. This application uses linq to sql. Can you tell me if I want to add these two new tables to the sql server 2008 r2 database, do I 1. Need to remove the original .dbml file and recreate the .dbml file? 2. I would think I can just add two tables to the database and somehow refresh the existing .dbml file. If this possible? Whatever your answer is to the question, can you tell me how to solve this problem?
classy_dog, double click on the dbml file and on the view menu choose server explorer add a link to the server your database is modeled from (you may already have one), you can click in any white space in the dbml diagram and look at the properties->connection->connection string to get the connection string. Once you have the server connection you can just drag the table(s) into the diagram.