Mysql Adonet ling女士视觉工作室c#

时间:2017-05-02 14:52:44

标签: mysql .net c#-4.0 linq-to-sql ado.net

我正在尝试使用Ado.net ling连接到数据库。我收到这个错误。我该怎么解决? VS 2015. EF5.0 .MySQL

enter image description here

namespace ExamSystem
{
    using System;
    using System.Data.Entity;
    using System.Data.Entity.Infrastructure;

    public partial class DB_Exam_Entities : DbContext
    {
        public DB_Exam_Entities()
            : base("name=DB_Exam_Entities")
        {
        }

        protected override void OnModelCreating(DbModelBuilder modelBuilder)
        {
            throw new UnintentionalCodeFirstException();
        }

        public DbSet<answer> answers { get; set; }
        public DbSet<correct_answer> correct_answer { get; set; }
        public DbSet<exam_archieve> exam_archieve { get; set; }
        public DbSet<exam_sub_subject> exam_sub_subject { get; set; }
        public DbSet<exam_subject> exam_subject { get; set; }
        public DbSet<exam> exams { get; set; }
        public DbSet<image> images { get; set; }
        public DbSet<question_type> question_type { get; set; }
        public DbSet<question> questions { get; set; }
        public DbSet<student_list> student_list { get; set; }
    }
}

0 个答案:

没有答案