Linq to SQL create table

I need to write a WPF (4.0) application that has a database but no tables. The application should create several tables in the database, and then start working with them. I am wondering if there is a way to do this in Linq for SQL?

+7
source share
1 answer

You can do this programmatically. those. you can programmatically create your own tables, according to the given parameters, you can also build relationships between tables ... :) Since there is no direct create table function, you can use the ExceuteCommand method for the DataContext to run some T-SQL statements to create tables.

+1
source

All Articles