This query works fine:
DetachedCriteria filter = DetachedCriteria
.For(typeof(NotificationRecord), "nr")
.Add(Expression.Eq("nr.Submission.Id", 5));
return ActiveRecordMediator<NotificationRecord>.FindAll(filter);
This query fails with the exception message: could not resolve property: Submission.IsScheduledForNotification of: NotificationRecord
DetachedCriteria filter = DetachedCriteria
.For(typeof(NotificationRecord), "nr")
.Add(Expression.Eq("nr.Submission.IsScheduledForNotification", true));
return ActiveRecordMediator<NotificationRecord>.FindAll(filter);
To ensure ActiveRecord is recognizing IsScheduledForNotification
, I do a simple query on the actual Submission
object using the IsScheduledForNotification
as filter like so and it works
ActiveRecordMediator<Submission>.Exists(Expression.Eq("IsScheduledForNotification", true));
Can someone say why this should happen?