LLBLGEN 2.6
ORM Support classes version 2.6.09.0305
Problem : After defining a field on related field ( 1:1 relation ship - the field is a string) and using the LLBLGENDataSource2 (adapter), I am getting an ORMInterpretationException : The expression has just 1 operand and the operand is null when trying to use the e.Sorter in the PerformSelect event. It only happens when trying to sort by the related field and not the other ones. The exception is thrown in the code segment that is highlighted in green. I have checked the sorter and it has the correct sort expression in it.
Thanks,
Brandt
protected void DS_CurrentSchedules_PerformSelect(object sender, SD.LLBLGen.Pro.ORMSupportClasses.PerformSelectEventArgs2 e)
{
if (this._pageController.Item != null)
{
var col = this._pageController.Item.CurrentOnCallScheduleCollection;
[colorvalue="00CC00"]col.Sorter = e.Sorter;[/color]
foreach (var ent in col)
{
e.ContainedCollection.Add(ent as EntityBase2);
}
}
}
public partial class ContactGroupEntity
{
public EntityView2<OnCallScheduleEntity> CurrentOnCallScheduleCollection
{
get
{
return new EntityView2<OnCallScheduleEntity>(OnCallScheduleCollection, OnCallScheduleFields.EndDate > DateTime.Now);
}
}
public EntityView2<OnCallScheduleEntity> PastOnCallScheduleCollection
{
get
{
return new EntityView2<OnCallScheduleEntity>(OnCallScheduleCollection, OnCallScheduleFields.EndDate < DateTime.Now);
}
}
}