Nhibernate 我怎样才能使用;表达式.Not“;有文本字段吗?

Nhibernate 我怎样才能使用;表达式.Not“;有文本字段吗?,nhibernate,castle-activerecord,Nhibernate,Castle Activerecord,如何在文本字段中使用“Expression.Not” 我需要从NHQuestionCount中选择除“ktest”之外的所有记录 例如,此代码返回运行时错误 NHQuestionCount[] stats = NHQuestionCount.FindAll(Order.Asc("NameFull"), Expression.Not(Expression.Eq("NameFull", "ktest"))); 我不能对代码的其余部分发表评论,但您对表达式的使用是完全正确的

如何在文本字段中使用“Expression.Not”

我需要从NHQuestionCount中选择除“ktest”之外的所有记录

例如,此代码返回运行时错误

NHQuestionCount[] stats = NHQuestionCount.FindAll(Order.Asc("NameFull"), Expression.Not(Expression.Eq("NameFull", "ktest")));

我不能对代码的其余部分发表评论,但您对表达式的使用是完全正确的