Entity framework 4 sql位允许null ef4

Entity framework 4 sql位允许null ef4,entity-framework-4,null,bit,Entity Framework 4,Null,Bit,我的数据库中有下表 表格问题 问题(i) 应答位为空 问题串 <Property Name="questionlog_id" Type="int" Nullable="false" oreGeneratedPattern="Identity" /> <Property Name="question_id" Type="int" Nullable="false" /> <Property Name="answer" Type=

我的数据库中有下表

表格问题

问题(i)

应答位为空

问题串

 <Property Name="questionlog_id" Type="int" Nullable="false" oreGeneratedPattern="Identity" />
          <Property Name="question_id" Type="int" Nullable="false" />
          <Property Name="answer" Type="bit" Nullable="true" />
q、 答案为假

如果我试图将其保存为null,则返回错误

questions q = new questions(){
question="blalala",
answer=null
} 
context.Addobject(q);
context.SaveChanges();
返回错误


如何将默认值设置为null

什么是异常/内部异常?问题实体是什么样子的?我从EDMX中添加了实体错误是不能将null转换为bool
questions q = new questions(){
question="blalala",
answer=null
} 
context.Addobject(q);
context.SaveChanges();