我的表是,
这些是表格。通常是作业表中列出的作业列表..我在所有其他表格中进行比较..
我的linq查询
public IQueryable<Job> GetJobs()
{
return (from job in _db.Jobs
from ep in _db.Emp.Plans
from al in _db.Alertsdone
from cvc in _db.CntactsViewed
join emps in _db.Emp.Reg.Details on job.OrganizationId equals emps.EmployerId into e
join alr in _db.Alertsdone on ep.Alerts equals alr.AlertsSent
join cv in _db.CntactsViewedon ep.Resumes equals cv.ContactsViewed
from emp in e.DefaultIfEmpty()
orderby job.OrganizationId != -1 descending, job.OrganizationId != null descending
orderby job.OrganizationId != -1 descending, emp.EmployerId == job.OrganizationId && alr.alertssent ==ep.alerts descending, job.CreatedDate descending
select job);
}
如果我这样给它显示空白页面..我正在尝试如果上述条件不存在意味着它应该订购其他选项,如orderby job.OrganizationId != -1 descending, job.OrganizationId != null descending
..而且我也放from emp in e.DefaultIfEmpty()
...但我错过了哪里?请帮帮我......