Here is my query so far. I'm getting exceptions about missing columns and a lack of projections.
var qf = new QueryFactory();
var query = qf.Create()
.From(qf.VwWeekenderChaletAllocationOrder
.Where(VwWeekenderChaletAllocationOrderFields.EventId == eventId)
.AndWhere(VwWeekenderChaletAllocationOrderFields.ForSale == true)
.AndWhere(VwWeekenderChaletAllocationOrderFields.Berth == berth)
.AndWhere(VwWeekenderChaletAllocationOrderFields.ChaletInstanceId != assignedParkChaletIds.ToArray()))
.Where(VwWeekenderChaletAllocationOrderFields.FloorBlockCount == quantity)
.OrderBy(VwWeekenderChaletAllocationOrderFields.ChaletClassId.Ascending(),
VwWeekenderChaletAllocationOrderFields.Block.Ascending(),
VwWeekenderChaletAllocationOrderFields.Floor.Descending(),
VwWeekenderChaletAllocationOrderFields.ParkChaletId.Ascending())
.Limit(quantity)
.WithProjector(r => new VwWeekenderChaletAllocationOrderEntity
{
});
var collection = new DataAccessAdapter().FetchQuery(query);
The gist of it is that I have an entity that I need to filter and then I need to filter the result and order it and end up with a list of the original entity.
How can I do this?