日期:2014-05-17 浏览次数:20449 次
public class Test
{
public int ID { get; set; }
public string FieldA { get; set; }
public string FieldB { get; set; }
}
public class TestDBContext : DbContext
{
public DbSet<Test> Test { get; set; }
}
<connectionStrings>
<add name="TestDBContext"
connectionString=" Data Source=.;
Initial Catalog=Test;Persist Security Info=True;
User ID=sa;Password=sa " providerName="System.Data.SqlClient"/>
</connectionStrings>